network device names change w/kernel version

andrew bezella abezella at archive.org
Thu May 8 17:46:04 CEST 2025


On Thu, 2025-05-08 at 23:13 +1200, Andrew Ruthven wrote:
> On Thu, 2025-05-08 at 08:54 +0200, Steffen Grunewald wrote:
> > On Wed, 2025-05-07 at 13:49:45 -0700, andrew bezella wrote:
> > > hello -
> > > 
> > > i'm running into a situation where the systemd network device
> > > naming
> > > changes with kernel version (bookworm/6.1 vs trixie/6.12 in this
> > > case).
> > > this is possibly related to a change/update in devlink support in
> > > the
> > > i40e driver[1] although i haven't found a "smoking gun" changelog
> > > entry.
> 
> It isn't the i40e driver, it is a change to "predictable interface
> names" in
> systemd. See https://systemd.io/PREDICTABLE_INTERFACE_NAMES/ . I
> don't find
> them so predictable, especially when there can be many interfaces in
> a host,
> and the PCIe slot layout can vary a lot.
> > 

thanks for the feedback; i should have been more clear.  i'm not
worried about transitioning to predictable interface names or wanting
to keep the `ethX` naming convention.  FAI's `scripts/DEBIAN/30-
interface` has the `newnicnames` function[1] that simulates the systemd
naming convention and our hardware is standard enough that we've
managed the transition to the systemd naming scheme.

and while it may not be the i40e driver, switching to the 6.12 bpo
kernel on a bookworm system (already using systemd predictable naming)
changes the interface names w/o an update to the naming scheme version:
# cat /etc/debian_version
12.10
# uname -vr
6.1.0-34-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.135-1 (2025-04-25)
# ip l show | grep -F " en" | cut -d: -f2
 eno1
    altname enp26s0f0
 eno2
    altname enp26s0f1
 enp94s0f0
 enp94s0f1
# udevadm info -e | grep -F ID_NET_NAMING_SCHEME=v252 | uniq
E: ID_NET_NAMING_SCHEME=v252
# udevadm info -e | grep -F ID_NET_NAME_ONBOARD=eno
E: ID_NET_NAME_ONBOARD=eno1
E: ID_NET_NAME_ONBOARD=eno2

while after a reboot into the bpo kernel:

# cat /etc/debian_version
12.10
# uname -vr
6.12.22+bpo-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.12.22-1~bpo12+1 (2025-04-25)
# ip l show | grep -F " en" | cut -d: -f2
 eno1np0
    altname enp26s0f0np0
 eno2np1
    altname enp26s0f1np1
 enp94s0f0np0
 enp94s0f1np1
# udevadm info -e | grep -F ID_NET_NAMING_SCHEME=v252 | uniq
E: ID_NET_NAMING_SCHEME=v252
# udevadm info -e | grep -F ID_NET_NAME_ONBOARD=eno
E: ID_NET_NAME_ONBOARD=eno1np0
E: ID_NET_NAME_ONBOARD=eno2np1

now that i look a little more closely, this appears to violate the
policy for the on-board naming schemes[2] that says it should end in
"o[[:digit:]]+" (paraphrased as it was confusing w/o italics).

> > Have you considered using the systemd.link (5) mechanism, and
> > choosing
> > a non-"eth*" name?
> 
> This is pretty much the approach we use, using enX as the interface
> names
> (ordered by the physical layout looking at the rear of a server). You
> can't
> use ethX as systemd refuses to rename things to ethX now. And can't
> use enoX
> for a similar reason.

thanks for the thought on systemd.link.  i hadn't realized you could
match on udev property names.  that looked like it might have potential
until the note about not being able to use "eno"; the goal would be to
match the existing systemd usage of exactly that prefix.

i think at this point it may be a bug (not following the on-board
naming schemes).  i'm going to ask around a little and maybe file as
such.  if it's changed behavior i think i may be looking for something
that's not possible and will start down the path of using the new
kernel for netbooting trixie+ and old kernel for older releases.

thanks again!

  andy

1. https://github.com/faiproject/fai-config/blob/f0e080dafbf5842768a68e938811f652aded8496/scripts/DEBIAN/30-interface#L47
2. https://www.freedesktop.org/software/systemd/man/latest/systemd.net-naming-scheme.html


More information about the linux-fai mailing list