"Predictable Network Interface Naming" suddenly changed the name from enp96s0f0 to enp96s0f0np0 causing outage
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
linux (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned | ||
systemd (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
On three identical servers - sleds in a blade chassis.
the NIC name of one of the servers suddenly changed, causing an outage. The netplan config could not assign IP to the interface due to the name change.
enp96s0f0 to enp96s0f0np0
The two other servers still have the enp96s0f0 name. No BIOS or other configuration change is detectable between the three systems. Firmware, software - all the same
I tried to debug this issue myself, but it turned out to be a very niche and complicated topic.
I went to submit an issue on https:/
System info:
dundts@
Description: Ubuntu 22.04.3 LTS
Release: 22.04
dundts@
system:
Installiert: 249.11-0ubuntu3.11
Installations
Versionstabelle:
249.
500 http://
*** 249.11-0ubuntu3.11 100
100 /var/lib/
249.
500 http://
249.
500 http://
dundts@
[sudo] password for dundts:
[ 3.657531] i40e: Intel(R) Ethernet Connection XL710 Network Driver
[ 3.658208] i40e: Copyright (c) 2013 - 2019 Intel Corporation.
[ 3.715866] i40e 0000:60:00.0: fw 3.1.54559 api 1.5 nvm 3.2d 0x80000b4b 1.1767.0 [8086:37d3] [152d:8a40]
[ 3.720222] i40e 0000:60:00.0: MAC address: d8:c4:97:4c:66:ae
[ 3.720558] i40e 0000:60:00.0: FW LLDP is enabled
[ 3.732613] i40e 0000:60:00.0: Added LAN device PF0 bus=0x60 dev=0x00 func=0x00
[ 3.733075] i40e 0000:60:00.0: Features: PF-id[0] VFs: 32 VSIs: 66 QP: 32 RSS FD_ATR FD_SB NTUPLE DCB VxLAN Geneve PTP VEPA
[ 3.788671] i40e 0000:60:00.1: fw 3.1.54559 api 1.5 nvm 3.2d 0x80000b4b 1.1767.0 [8086:37d3] [152d:8a40]
[ 3.804478] i40e 0000:60:00.1: MAC address: d8:c4:97:4c:66:af
[ 3.804964] i40e 0000:60:00.1: FW LLDP is enabled
[ 3.839982] i40e 0000:60:00.1 eth1: NIC Link is Up, 10 Gbps Full Duplex, Flow Control: None
[ 3.851939] i40e 0000:60:00.1: Added LAN device PF1 bus=0x60 dev=0x00 func=0x01
[ 3.877994] i40e 0000:60:00.1: Features: PF-id[1] VFs: 32 VSIs: 66 QP: 32 RSS FD_ATR FD_SB NTUPLE DCB VxLAN Geneve PTP VEPA
[ 4.065330] i40e 0000:60:00.0 enp96s0f0np0: renamed from eth0
[ 4.096320] i40e 0000:60:00.1 enp96s0f1np1: renamed from eth1
dundts@
P: /devices/
L: 0
E: DEVPATH=
E: INTERFACE=
E: IFINDEX=2
E: SUBSYSTEM=net
E: USEC_INITIALIZE
E: ID_MM_CANDIDATE=1
E: ID_NET_
E: ID_NET_
E: ID_OUI_
E: ID_NET_
E: ID_BUS=pci
E: ID_VENDOR_ID=0x8086
E: ID_MODEL_ID=0x37d3
E: ID_PCI_
E: ID_PCI_
E: ID_VENDOR_
E: ID_MODEL_
E: ID_PATH=
E: ID_PATH_
E: ID_NET_DRIVER=i40e
E: ID_NET_
E: ID_NET_
E: NM_UNMANAGED=1
E: SYSTEMD_
E: TAGS=:systemd:
E: CURRENT_
By default (and as we can see in the ID_NET_LINK_FILE= property above), the name policy is controlled by NamePolicy= in /usr/lib/ systemd/ network/ 99-default. link. On Jammy, this looks like:
root@jammy:~# cat /lib/systemd/ network/ 99-default. link Identifier: LGPL-2.1-or-later
# SPDX-License-
#
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
[Match]
OriginalName=*
[Link] sPolicy= database onboard slot path y=persistent
NamePolicy=keep kernel database onboard slot path
AlternativeName
MACAddressPolic
Basically, udev will try those policies in order until one matches. Based on the udev properties above, it looks like the 'path' policy was selected. This *might* different than before, or maybe something else changed on the system that then changed resulting name constructed by udev.
Can you please enable debug logs for udev (ideally on both a working and non-working system), and share them here? E.g.
$ mkdir -p /etc/systemd/ system/ systemd- udevd.service. d system/ systemd- udevd.service. d/debug. conf << EOF SYSTEMD_ LOG_LEVEL= debug
$ cat > /etc/systemd/
[Service]
Environment=
EOF
Then, reboot, and then run:
$ journalctl -u systemd- udevd.service -b > udev.log
and attach the result.