-
-
Notifications
You must be signed in to change notification settings - Fork 248
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
NDB Kernel not sending RTM_DELROUTE #1188
Comments
That's right, you need to subscribe to |
@crosser thank you for that, that makes sense. So to get back to my example: ip a a 172.16.1.1/24 dev veth1 this will also trigger a RTM_DELNEXTHOP but no RTM_DELROUTE. |
We did not run into this use case (yet?), and not handling it. |
@svenauhagen your test case looks odd to me. The last command is |
@crosser you are correct, that is a copy and paste error. |
I pushed a PR for the case that the last address is removed from an interface with multipath routes |
If a route is using neighbours as gateway and the neighbour is deleted, the kernel does not send a RTM_DELROUTE and therefore the NDB cache is incorrect.
How to reproduce:
run ip monitor
and in a second window do:
ip a a 172.16.1.1/24 dev veth1
ip nexthop add id 100 via 172.16.1.2 dev veth1
ip route add 172.16.101.0/24 nhid 100
ip nexthop del id 100
replace IP and dev with your local settings.
The kernel will send a RTM_DELNEXTHOP but no RTM_DELROUTE.
For IPv6 the behaviour can be controlled with a sysctl skip_notify_on_dev_down but not in IPv4.
I guess we would need to listen for RTM_DELNEXTHOP remove them from the neighbourhood table and if it is the last entry for a route also delete that route.
What do you think?
Best
Sven
The text was updated successfully, but these errors were encountered: