• Bug#1105204: udev: networking broken by interface name change upgrading

    From Emanuele Rocca@21:1/5 to All on Tue May 13 12:40:01 2025
    Package: udev
    Version: 257.5-2
    Severity: important

    Hi!

    We tested a bookworm to trixie update on one of our systems. The host
    did not come back online after reboot, and the issue seems to be caused
    by the 252 -> 257 systemd update.

    The main network interface on the system was named "enp1s0" by systemd
    252.36 shipped with bookworm. After upgrading the machine to trixie and rebooting, the host was unreachable via the network. Logging in via out-of-bound console it became evident that systemd v257 on trixie chose
    a different name for the network interface: "ens1".

    After rebooting the machine passing net.naming_scheme=v252 to the kernel command line, we verified that the interface name went back to "enp1s0".

    The important change seems to be that v257 sets ID_NET_NAME_SLOT=ens1,
    and *that* is chosen as the interface name to use instead of ID_NET_NAME_PATH=enp1s0.

    Here's the diff of `udevadm test-builtin net_id /sys/class/net/$IFACE`

    --- v252.txt 2025-05-12 20:44:42.252702652 +0200
    +++ v257.txt 2025-05-12 20:43:50.668953530 +0200
    @@ -11,7 +11,7 @@
    Loading kernel module index.
    Loaded 'libkmod.so.2' via dlopen()
    Found container virtualization none.
    -Using interface naming scheme 'v252'.
    +Using default interface naming scheme 'v257'.
    Parsed configuration file "/usr/lib/systemd/network/99-default.link"
    Parsed configuration file "/usr/lib/systemd/network/80-vm-vt.link"
    Parsed configuration file "/usr/lib/systemd/network/80-container-vz.link"
    @@ -20,10 +20,12 @@
    Parsed configuration file "/usr/lib/systemd/network/80-6rd-tunnel.link"
    Parsed configuration file "/usr/lib/systemd/network/73-usb-net-by-mac.link"
    Created link configuration context.
    -ID_NET_NAMING_SCHEME=v252
    +ID_NET_NAMING_SCHEME=v257
    ID_NET_NAME_MAC=enx001b21e7ca26
    enp1s0: MAC address identifier: hw_addr=00:1b:21:e7:ca:26 → x001b21e7ca26
    ID_OUI_FROM_DATABASE=Intel Corporate
    +sd-device: Failed to chase symlinks in "/sys/devices/pci0000:00/0000:00:01.
  • From Luca Boccassi@21:1/5 to All on Wed May 21 23:50:01 2025
    Control: forcemerge 1105204 1105223
    Control: tags 1105204 wontfix
    Control: close 1105204

    On Tue, 13 May 2025 12:31:41 +0200 Emanuele Rocca <ema@debian.org>
    wrote:
    Package: udev
    Version: 257.5-2
    Severity: important

    Hi!

    We tested a bookworm to trixie update on one of our systems. The host
    did not come back online after reboot, and the issue seems to be
    caused
    by the 252 -> 257 systemd update.

    The main network interface on the system was named "enp1s0" by
    systemd
    252.36 shipped with bookworm. After upgrading the machine to trixie
    and
    rebooting, the host was unreachable via the network. Logging in via out-of-bound console it became evident that systemd v257 on trixie
    chose
    a different name for the network interface: "ens1".

    After rebooting the machine passing net.naming_scheme=v252 to the
    kernel
    command line, we verified that the interface name went back to
    "enp1s0".

    This is expected due to kernel changes. Names can always change if the
    kernel changes its internal behaviour, you have to fix them if you
    don't want that to happen. This is documented at:

    https://www.freedesktop.org/software/systemd/man/latest/systemd.net-naming-scheme.html

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Emanuele Rocca@21:1/5 to Luca Boccassi on Thu Jun 5 14:10:01 2025
    Hi Luca,

    On 2025-05-21 10:39, Luca Boccassi wrote:
    This is expected due to kernel changes. Names can always change if the
    kernel changes its internal behaviour, you have to fix them if you
    don't want that to happen. This is documented at:

    https://www.freedesktop.org/software/systemd/man/latest/systemd.net-naming-scheme.html

    Does this mean that all interfaces called enpXs0 on Bookworm will be
    renamed to ensX when upgrading to Trixie?

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)