RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2027908 - Network interface names are not necessarily predictable and don't match previous names
Summary: Network interface names are not necessarily predictable and don't match previ...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 8
Classification: Red Hat
Component: systemd
Version: 8.5
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: rc
: ---
Assignee: systemd-maint
QA Contact: Frantisek Sumsal
URL:
Whiteboard:
Depends On: 2005008 2022432
Blocks: 2030027
TreeView+ depends on / blocked
 
Reported: 2021-12-01 02:54 UTC by Shannon Nelson
Modified: 2022-05-10 16:45 UTC (History)
9 users (show)

Fixed In Version: systemd-239-58.el8
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2030027 (view as bug list)
Environment:
Last Closed: 2022-05-10 15:25:48 UTC
Type: Bug
Target Upstream Version:
Embargoed:
pm-rhel: mirror+


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker RHELPLAN-104391 0 None None None 2021-12-01 04:50:28 UTC
Red Hat Product Errata RHBA-2022:2069 0 None None None 2022-05-10 15:26:32 UTC

Internal Links: 1827462

Description Shannon Nelson 2021-12-01 02:54:29 UTC
A past problem had udev generating incorrect names (bz1827462), but that
seems to be fixed.  This is a different problem.

When booting up an HPE:ProLiant DL360 Gen10 running RHEL 8.5 with kernel
4.18.0-348.2.1.el8_5.x86_64 that has our Pensando DSC NIC, using the
ionic driver, we would expect to see names such as enp57s0 and enp58s0
for these interfaces.  However, we see devices named ens2 and eth0.  If
we unload the ionic driver and reload it, we now see interfaces eth1 and eth2.

Hence, names we didn't expect, and not predictable.

In the messages log we see entries like this:
Nov 29 12:39:27 sln-dev systemd-udevd[1273]: Using default interface naming scheme 'rhel-8.0'.
Nov 29 12:39:27 sln-dev systemd-udevd[1273]: link_config: autonegotiation is unset or enabled, the speed and duplex are not writable.
Nov 29 12:39:27 sln-dev systemd-udevd[1273]: Could not set AlternativeName= or apply AlternativeNamesPolicy= on ens2: File exists
Nov 29 12:39:27 sln-dev systemd-udevd[1273]: Could not apply link config to ens2, ignoring: File exists
Nov 29 12:39:27 sln-dev systemd-udevd[1273]: Error changing net interface name 'ens2' to 'enp57s0': File exists
Nov 29 12:39:27 sln-dev systemd-udevd[1273]: could not rename interface '8' from 'ens2' to 'enp57s0': File exists

After some experimentation with unloading and loading the driver, I found that simply
commenting out the AlternativeNamesPolicy line in /usr/lib/systemd/network/99-default.link
was a way to stop these errors and to get the expected interface names.  I also had to
rebuild the initramfs since it also has this configuration and does the initial interface
setup at boot time.

udev info with AlternativeNamesPolicy:

# udevadm info /sys/class/net/eth0   
P: /devices/pci0000:36/0000:36:00.0/0000:37:00.0/0000:38:00.0/0000:39:00.0/net/eth0
E: DEVPATH=/devices/pci0000:36/0000:36:00.0/0000:37:00.0/0000:38:00.0/0000:39:00.0/net/eth0
E: ID_BUS=pci
E: ID_MODEL_FROM_DATABASE=DSC Ethernet Controller (Naples 25Gb 2-port SFP28 x8 4GB)
E: ID_MODEL_ID=0x1002
E: ID_NET_DRIVER=ionic
E: ID_NET_LINK_FILE=/usr/lib/systemd/network/99-default.link
E: ID_NET_NAME_MAC=enx00aecd05bd40
E: ID_NET_NAME_PATH=enp57s0
E: ID_NET_NAME_SLOT=ens2
E: ID_NET_NAMING_SCHEME=rhel-8.0
E: ID_OUI_FROM_DATABASE=Pensando Systems
E: ID_PATH=pci-0000:39:00.0
E: ID_PATH_TAG=pci-0000_39_00_0
E: ID_PCI_CLASS_FROM_DATABASE=Network controller
E: ID_PCI_SUBCLASS_FROM_DATABASE=Ethernet controller
E: ID_VENDOR_FROM_DATABASE=Pensando Systems
E: ID_VENDOR_ID=0x1dd8
E: IFINDEX=8
E: INTERFACE=eth0
E: SUBSYSTEM=net
E: SYSTEMD_ALIAS=/sys/subsystem/net/devices/enp57s0
E: TAGS=:systemd:
E: USEC_INITIALIZED=4642629

udev info with no AlternativeNamesPolicy:

# udevadm info /sys/class/net/enp57s0
P: /devices/pci0000:36/0000:36:00.0/0000:37:00.0/0000:38:00.0/0000:39:00.0/net/enp57s0
E: DEVPATH=/devices/pci0000:36/0000:36:00.0/0000:37:00.0/0000:38:00.0/0000:39:00.0/net/enp57s0
E: ID_BUS=pci
E: ID_MODEL_FROM_DATABASE=DSC Ethernet Controller (Naples 25Gb 2-port SFP28 x8 4GB)
E: ID_MODEL_ID=0x1002
E: ID_NET_DRIVER=ionic
E: ID_NET_LINK_FILE=/usr/lib/systemd/network/99-default.link
E: ID_NET_NAME=ens2
E: ID_NET_NAME_MAC=enx00aecd05bd40
E: ID_NET_NAME_PATH=enp57s0
E: ID_NET_NAME_SLOT=ens2
E: ID_NET_NAMING_SCHEME=rhel-8.0
E: ID_OUI_FROM_DATABASE=Pensando Systems
E: ID_PATH=pci-0000:39:00.0
E: ID_PATH_TAG=pci-0000_39_00_0
E: ID_PCI_CLASS_FROM_DATABASE=Network controller
E: ID_PCI_SUBCLASS_FROM_DATABASE=Ethernet controller
E: ID_VENDOR_FROM_DATABASE=Pensando Systems
E: ID_VENDOR_ID=0x1dd8
E: IFINDEX=8
E: INTERFACE=enp57s0
E: SUBSYSTEM=net
E: SYSTEMD_ALIAS=/sys/subsystem/net/devices/enp57s0 /sys/subsystem/net/devices/enp57s0
E: TAGS=:systemd:
E: USEC_INITIALIZED=5293134

Comment 1 David Tardon 2021-12-02 16:24:02 UTC
Indeed. I didn't realize the consequences of bug 2022432. We'll have to move the new name assignment before alt. names handling if it is not fixed.

(In any case, that the new name is assigned as the very last step in link_config_apply() seems unnecessarily fragile to me. IMHO setting of ID_NET_NAME= should not depend upon successful setting of link properties and whatnot.)

Comment 12 errata-xmlrpc 2022-05-10 15:25:48 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (systemd bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2022:2069


Note You need to log in before you can comment on or make changes to this bug.