-
Notifications
You must be signed in to change notification settings - Fork 88
bridge: Fix decode error on bridge with IFLA_BR_MCAST_QUERIER_STATE #247
Conversation
With kernel supporting `IFLA_BR_MCAST_QUERIER_STATE`, we got error: Decode error occurred: Failed to parse message with type 16 After painfull debug, this is caused by IFLA_BRIDGE_FLAGS holding the same value as `IFLA_BR_MCAST_QUERIER_STATE` and expecting the payload been a u16. This is incorrect: * `IFLA_BRIDGE_FLAGS` is 0, and for `IFLA_AF_SPEC`, not `IFLA_LINKINFO`. * `IFLA_BR_MCAST_QUERIER_STATE` is a nested netlink attribute, not u16 which cause this failure. I have no project needing the support `IFLA_BR_MCAST_QUERIER_STATE` of it yet, so this patch just remove `IFLA_BRIDGE_FLAGS`, `IFLA_BRIDGE_VLAN_INFO`, and their associates. Also reordering the order of parsing `IFLA_LINKINFO` for bridge, to match the numeric order. So the developer could easily compare it to `/usr/include/linux/if_link.h`. Signed-off-by: Gris Ge <[email protected]>
73bbdd7
to
f86f418
Compare
@little-dude This bug is breaking my project. Please review and tag new release afterwards. The use of |
@ffmancera The impact of this bug: it stop nmstate/nispor on all linux bridge related tasks. In case you ran into also. |
Regarding I'm on vacation for two weeks so I won't be able to review this before, sorry. Is this a case where different kernels will expect a different message format as in #44 ? |
No, it is not a kernel version specific difference. The last modifcation regarding [2469ffd72] net: set and query VEB/VEPA bridge mode via PF_BRIDGE John Fastabend (2012-10-24 04:13:03 PM) Which is 10 years ago. |
Regarding the anyhow preserving lower level errors, it is not happening in this project. This is the full debug log: It only contains the error: |
Due to issue of little-dude/netlink#247 , nispor could not show contain bridge on kernel supporting `IFLA_BR_MCAST_QUERIER_STATE`. Instead of waiting rust-netlink to tag new release, we are including patched `netlink-package-route` into this project and switch to upstream once they have new release. Signed-off-by: Gris Ge <[email protected]>
Due to issue of little-dude/netlink#247 , nispor could not show contain bridge with `IFLA_BR_MCAST_QUERIER_STATE` data. Instead of waiting rust-netlink to tag new release, we are including patched `netlink-package-route` into this project and switch to upstream once they have new release. Signed-off-by: Gris Ge <[email protected]>
Due to issue of little-dude/netlink#247 , nispor could not show contain bridge with `IFLA_BR_MCAST_QUERIER_STATE` data. Instead of waiting rust-netlink to tag new release, we are including patched `netlink-package-route` into this project and switch to upstream once they have new release. Signed-off-by: Gris Ge <[email protected]>
It seems #222 also removes |
Close in favor of #222 |
The nispor 1.2.6 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
The nispor 1.2.6 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
The nispor 1.2.6 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
The nispor 1.2.7 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
The nispor 1.2.7 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
The nispor 1.2.7 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
The nispor 1.2.7 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
The nispor 1.2.7 fixed the linux bridge bug: little-dude/netlink#247 Which is important to nmstate Signed-off-by: Gris Ge <[email protected]>
With kernel supporting
IFLA_BR_MCAST_QUERIER_STATE
, we got error:After painfull debug, this is caused by IFLA_BRIDGE_FLAGS holding the
same value as
IFLA_BR_MCAST_QUERIER_STATE
and expecting the payloadbeen a u16.
This is incorrect:
IFLA_BRIDGE_FLAGS
is 0, and forIFLA_AF_SPEC
, notIFLA_LINKINFO
.IFLA_BR_MCAST_QUERIER_STATE
is a nested netlink attribute, not u16which cause this failure.
I have no project needing the support
IFLA_BR_MCAST_QUERIER_STATE
ofit yet, so this patch just remove
IFLA_BRIDGE_FLAGS
,IFLA_BRIDGE_VLAN_INFO
, and their associates.Also reordering the order of parsing
IFLA_LINKINFO
for bridge, tomatch the numeric order. So the developer could easily compare it to
/usr/include/linux/if_link.h
.