Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fail to set mac when setting bonding interface #220

Open
haosdent opened this issue Jul 10, 2018 · 7 comments
Open

fail to set mac when setting bonding interface #220

haosdent opened this issue Jul 10, 2018 · 7 comments

Comments

@haosdent
Copy link
Contributor

Encounter following error when setting binding interface

Kni: kni_add_dev: fail to set mac 00:00:00:00:00:00 for bond1.kni: Cannot assign requested address

is it ignorable?

@beacer
Copy link
Contributor

beacer commented Jul 11, 2018

kni devices' MAC are derived from real device, for your example it is bond1. pls make sure when kni_add_dev is invoked, the MAC of bond1 is exist, not all-zero. You may need check the function netif_port_init or kni_add_dev.

@haosdent
Copy link
Contributor Author

the MAC of bond1 is exist

I am able to see bond1 via

# dpip link show
1: dpdk2: socket 0 mtu 1500 rx-queue 8 tx-queue 8
    UP 10000 Mbps full-duplex auto-nego
    addr B4:96:91:15:C5:74 OF_RX_IP_CSUM OF_TX_IP_CSUM OF_TX_TCP_CSUM OF_TX_UDP_CSUM
2: dpdk3: socket 0 mtu 1500 rx-queue 8 tx-queue 8
    UP 10000 Mbps full-duplex auto-nego
    addr B4:96:91:15:C5:76 OF_RX_IP_CSUM OF_TX_IP_CSUM OF_TX_TCP_CSUM OF_TX_UDP_CSUM
3: bond1: socket 0 mtu 1500 rx-queue 8 tx-queue 8
    UP 20000 Mbps full-duplex auto-nego
    addr B4:96:91:15:C5:74

this looks correct?

@beacer
Copy link
Contributor

beacer commented Jul 11, 2018

Is it already exist when system bootup, when netif_init->netif_port_init->kni_add_dev ? the error log shows 00:00:00:00:00:00 is set.

@haosdent
Copy link
Contributor Author

Is it already exist when system bootup

If I didn't launch dpvs, could not see bond1 via dpip link show or ip link show. After I start dpvs,
I able to see bond1 and bond1.kni.

@haosdent
Copy link
Contributor Author

In kni_add_dev, when dev->addr would be assigned a mac addr?

    err = linux_set_if_mac(conf.name, (unsigned char *)&dev->addr);

I add log to print it before

    err = linux_set_if_mac(conf.name, (unsigned char *)&dev->addr);

looks like dev->addr is 00:00:00

@beacer
Copy link
Contributor

beacer commented Jul 11, 2018

it means bond1's mac is 00:00:00 when netif_port_init, need found out why.

@haosdent
Copy link
Contributor Author

yep, thanks @beacer . let me add more debug logs in my side and check the reason

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants