Uploaded image for project: 'RHEL'
  1. RHEL
  2. RHEL-44559

dracut includes systemd.link files in initramfs causing networking to break

Linking RHIVOS CVEs to...Migration: Automation ...SWIFT: POC ConversionSync from "Extern...XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Can't Do
    • Icon: Normal Normal
    • None
    • CentOS Stream 9
    • NetworkManager
    • None
    • None
    • Assignee, Qa Contact, Doc Contact, AssignedTeam, Watchers, Developer
    • Moderate
    • rhel-net-mgmt
    • ssg_networking
    • 3
    • False
    • False
    • Hide

      None

      Show
      None
    • None
    • None
    • None
    • None
    • None

      What were you trying to do that didn't work?

      Upgrade a system from dracut-057-44.git20230822.el9 to dracut-057-53.git20240104.el9. After upgrade, the network interfaces did not come up.

      Please provide the package NVR for which bug is seen: dracut-057-53.git20240104.el9.x86_64

      How reproducible: Always

      Steps to reproduce

      1. On a system that renames ethernet interfaces using systemd.link files and uses active-backup bonding, upgrade dracut and regenerate initramfs
      2. Reboot
      3. Observe that the network links did not come up properly. I see the correct devices in ip link, but the underlying network devices are not up, and the bond devices show NO-CARRIER

      Expected results

      A system with working network interfaces:

      [root@ti128 ~]# ip link ls
      1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
          link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
      2: lan0: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 1500 qdisc mq master bond0 state UP mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:71 brd ff:ff:ff:ff:ff:ff permaddr 00:15:17:9e:0b:70
      3: lan1: <BROADCAST,MULTICAST,SLAVE,UP,LOWER_UP> mtu 1500 qdisc mq master bond0 state UP mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:70 brd ff:ff:ff:ff:ff:ff permaddr 00:15:17:9e:0b:71
      4: bond0: <BROADCAST,MULTICAST,MASTER,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:70 brd ff:ff:ff:ff:ff:ff
      5: bond0.3005@bond0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:70 brd ff:ff:ff:ff:ff:ff
      6: bond0.3013@bond0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:70 brd ff:ff:ff:ff:ff:ff
      7: bond0.3003@bond0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:70 brd ff:ff:ff:ff:ff:ff

      Actual results

      [root@ti128 ~]# ip link ls
      1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000
          link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
      2: lan0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:70 brd ff:ff:ff:ff:ff:ff
      3: lan1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
          link/ether 00:15:17:9e:0b:71 brd ff:ff:ff:ff:ff:ff
      4: bond0: <NO-CARRIER,BROADCAST,MULTICAST,MASTER,UP> mtu 1500 qdisc noqueue state DOWN mode DEFAULT group default qlen 1000
          link/ether 22:47:40:d7:b8:d3 brd ff:ff:ff:ff:ff:ff
      5: bond0.3005@bond0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
          link/ether 22:47:40:d7:b8:d3 brd ff:ff:ff:ff:ff:ff
      6: bond0.3013@bond0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
          link/ether 22:47:40:d7:b8:d3 brd ff:ff:ff:ff:ff:ff
      7: bond0.3003@bond0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state LOWERLAYERDOWN mode DEFAULT group default qlen 1000
          link/ether 22:47:40:d7:b8:d3 brd ff:ff:ff:ff:ff:ff

       

      When I use  lsinitrd --unpack to compare the contents of the initramfs before and after the upgrade, I see that the upgraded initramfs includes these systemd.link files that were not included in the previous version:

       

      [root@ti128 dracut-057-53.git20240104.el9]# head etc/systemd/network/10-ti-lan*
      ==> etc/systemd/network/10-ti-lan0.link <==
      [Match]
      MACAddress=00:15:17:9e:0b:70
      Type=!vlan

      [Link]
      Name=lan0

      ==> etc/systemd/network/10-ti-lan1.link <==
      [Match]
      MACAddress=00:15:17:9e:0b:71
      Type=!vlan

      [Link]
      Name=lan1

      My suspicion is that the inclusion of these files in the initramfs is somehow leading to brain damage, although I'm not sure why.

       

      In case it  matters, my system is using legacy /etc/sysconfig/network-scripts/ifcfg-* files to configure the interfaces:

      [root@ti128 ~]# head 50 /etc/sysconfig/network-scripts/ifcfg*
      ==> /etc/sysconfig/network-scripts/ifcfg-bond0 <==
      DEVICE=bond0
      TYPE=Bond
      BOOTPROTO=static
      ONBOOT=yes
      HOTPLUG=no
      NOZEROCONF=yes
      NM_CONTROLLED=yes
      IPADDR=192.168.50.128
      NETMASK=255.255.254.0
      BONDING_MASTER=yes
      BONDING_OPTS="miimon=0 mode=active-backup arp_all_targets=any primary=lan1 arp_ip_target=192.168.50.38,192.168.50.34,192.168.50.122,192.168.50.50 arp_interval=1000 fail_over_mac=follow arp_validate=none primary_reselect=always"

      ==> /etc/sysconfig/network-scripts/ifcfg-bond0.3003 <==
      DEVICE=bond0.3003
      BOOTPROTO=static
      ONBOOT=yes
      HOTPLUG=no
      NOZEROCONF=yes
      NM_CONTROLLED=yes
      VLAN=yes
      IPADDR=192.168.53.128
      NETMASK=255.255.255.0

      ==> /etc/sysconfig/network-scripts/ifcfg-bond0.3005 <==
      DEVICE=bond0.3005
      BOOTPROTO=static
      ONBOOT=yes
      HOTPLUG=no
      NOZEROCONF=yes
      NM_CONTROLLED=yes
      VLAN=yes
      IPADDR=192.168.55.128
      NETMASK=255.255.255.0

      ==> /etc/sysconfig/network-scripts/ifcfg-bond0.3013 <==
      DEVICE=bond0.3013
      BOOTPROTO=static
      ONBOOT=yes
      HOTPLUG=no
      NOZEROCONF=yes
      NM_CONTROLLED=yes
      VLAN=yes
      IPADDR=192.168.63.128
      NETMASK=255.255.255.0

      ==> /etc/sysconfig/network-scripts/ifcfg-lan0 <==
      DEVICE=lan0
      TYPE=Ethernet
      BOOTPROTO=none
      ONBOOT=yes
      HOTPLUG=no
      NOZEROCONF=yes
      NM_CONTROLLED=yes
      MASTER=bond0
      SLAVE=yes

      ==> /etc/sysconfig/network-scripts/ifcfg-lan1 <==
      DEVICE=lan1
      TYPE=Ethernet
      BOOTPROTO=none
      ONBOOT=yes
      HOTPLUG=no
      NOZEROCONF=yes
      NM_CONTROLLED=yes
      MASTER=bond0
      SLAVE=yes

              nm-team Network Management Team
              ajschorr Andrew Schorr (Inactive)
              qe-baseos-daemons qe-baseos-daemons
              Votes:
              0 Vote for this issue
              Watchers:
              11 Start watching this issue

                Created:
                Updated:
                Resolved: