All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: "Muggeridge, Matt" <matt.muggeridge2@hpe.com>
Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: Re: "ip route show dev enp0s9" does not show all routes for enp0s9
Date: Thu, 27 Jun 2024 19:36:32 -0700	[thread overview]
Message-ID: <20240627193632.5ea88216@hermes.local> (raw)
In-Reply-To: <SJ0PR84MB2088DCBDCCCD49FFB9DFFBAAD8D02@SJ0PR84MB2088.NAMPRD84.PROD.OUTLOOK.COM>

On Fri, 28 Jun 2024 00:01:47 +0000
"Muggeridge, Matt" <matt.muggeridge2@hpe.com> wrote:

> Hi,
> 
> This looks like a problem in "iproute2".  This was observed on a fresh install of Ubuntu 24.04, with Linux 6.8.0-36-generic.
> 
> NOTE: I first raised this in https://bugs.launchpad.net/ubuntu/+source/iproute2/+bug/2070412, then later found https://github.com/iproute2/iproute2/blob/main/README.devel.
> 
> * PROBLEM
> Compare the outputs:
> 
> $ ip -6 route show dev enp0s9
> 2001:2:0:1000::/64 proto ra metric 1024 expires 65518sec pref medium
> fe80::/64 proto kernel metric 256 pref medium
> 
> $ ip -6 route
> 2001:2:0:1000::/64 dev enp0s9 proto ra metric 1024 expires 65525sec pref medium
> fe80::/64 dev enp0s3 proto kernel metric 256 pref medium
> fe80::/64 dev enp0s9 proto kernel metric 256 pref medium
> default proto ra metric 1024 expires 589sec pref medium
>  nexthop via fe80::200:10ff:fe10:1060 dev enp0s9 weight 1
>  nexthop via fe80::200:10ff:fe10:1061 dev enp0s9 weight 1
> 
> The default route is associated with enp0s9, yet the first command above does not show it.
> 
> FWIW, the two default route entries were created by two separate routers on the network, each sending their RA.
> 
> * REPRODUCER
> Statically Configure systemd-networkd with two route entries, similar to the following:
> 
> $ networkctl cat 10-enp0s9.network
> # /etc/systemd/network/10-enp0s9.network
> [Match]
> Name=enp0s9
> 
> [Link]
> RequiredForOnline=no
> 
> [Network]
> Description="Internal Network: Private VM-to-VM IPv6 interface"
> DHCP=no
> LLDP=no
> EmitLLDP=no
> 
> 
> # /etc/systemd/network/10-enp0s9.network.d/address.conf
> [Network]
> Address=2001:2:0:1000:a00:27ff:fe5f:f72d/64
> 
> 
> # /etc/systemd/network/10-enp0s9.network.d/route-1060.conf
> [Route]
> Gateway=fe80::200:10ff:fe10:1060
> GatewayOnLink=true
> 
> 
> # /etc/systemd/network/10-enp0s9.network.d/route-1061.conf
> [Route]
> Gateway=fe80::200:10ff:fe10:1061
> GatewayOnLink=true
> 
> 
> 
> Now reload and reconfigure the interface and you will see two routes.
> 
> $ networkctl reload
> $ networkctl reconfigure enp0s9
> $ ip -6 r
> $ ip -6 r show dev enp0s9 # the routes are not shown
> 

"Don't blame the messenger", the ip command only reports what the kernel
sends. So it is likely a route semantics issue in the kernel.


  reply	other threads:[~2024-06-28  2:36 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-28  0:01 "ip route show dev enp0s9" does not show all routes for enp0s9 Muggeridge, Matt
2024-06-28  2:36 ` Stephen Hemminger [this message]
2024-06-28  2:54   ` Muggeridge, Matt
2024-06-30 10:39     ` Ido Schimmel
2024-06-30 16:23       ` Stephen Hemminger
2024-07-01  7:17         ` Ido Schimmel
  -- strict thread matches above, loose matches on Subject: below --
2024-07-03  4:00 Muggeridge, Matt
2024-07-03  5:50 ` Stephen Hemminger
2024-07-03 19:46   ` Muggeridge, Matt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20240627193632.5ea88216@hermes.local \
    --to=stephen@networkplumber.org \
    --cc=matt.muggeridge2@hpe.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.