dpvs
dpvs copied to clipboard
fail to set mac when setting bonding interface
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?
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
.
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?
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.
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.
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
it means bond1
's mac is 00:00:00
when netif_port_init
, need found out why.
yep, thanks @beacer . let me add more debug logs in my side and check the reason