netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* RTM_DELROUTE not sent anymore when deleting (last) nexthop of routes in 6.1
@ 2022-11-24  9:20 Jonas Gorski
  2022-11-24 12:41 ` Ido Schimmel
  2022-11-25  8:36 ` RTM_DELROUTE not sent anymore when deleting (last) nexthop of routes in 6.1 #forregzbot Thorsten Leemhuis
  0 siblings, 2 replies; 12+ messages in thread
From: Jonas Gorski @ 2022-11-24  9:20 UTC (permalink / raw)
  To: Network Development; +Cc: David Ahern

Hello,

when an IPv4 route gets removed because its nexthop was deleted, the
kernel does not send a RTM_DELROUTE netlink notifications anymore in
6.1. A bisect lead me to 61b91eb33a69 ("ipv4: Handle attempt to delete
multipath route when fib_info contains an nh reference"), and
reverting it makes it work again.

It can be reproduced by doing the following and listening to netlink
(e.g. via ip monitor)

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

where the nexthop del will trigger a RTM_DELNEXTHOP message, but no
RTM_DELROUTE, but the route is gone afterwards anyways.

Doing the same thing with IPv6 still works as expected

ip a a 2001:db8:91::1/64 dev veth1
ip nexthop add id 100 via 2001:db8:91::2 dev veth1
ip route add 2001:db8:101::/64 nhid 100
ip nexthop del id 100

Here the kernel will send out both the RTM_DELNEXTHOP and the
RTM_DELROUTE netlink messages.

Unfortunately my net-foo is not good enough to propose a fix.

Best regards
Jonas

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-11-29  8:51 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-24  9:20 RTM_DELROUTE not sent anymore when deleting (last) nexthop of routes in 6.1 Jonas Gorski
2022-11-24 12:41 ` Ido Schimmel
2022-11-24 14:15   ` Jonas Gorski
2022-11-24 14:40     ` Jonas Gorski
2022-11-24 14:50       ` Ido Schimmel
2022-11-24 15:20         ` Jonas Gorski
2022-11-24 16:04           ` Ido Schimmel
2022-11-24 16:58             ` Jonas Gorski
2022-11-25  3:53   ` David Ahern
2022-11-25  8:36 ` RTM_DELROUTE not sent anymore when deleting (last) nexthop of routes in 6.1 #forregzbot Thorsten Leemhuis
2022-11-27 12:08   ` Thorsten Leemhuis
2022-11-29  8:50     ` Thorsten Leemhuis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).