interface names mess - predictable interfaces names broken

  • Hi all!

    When booting the OMV 7 today (runs on QNAP TS-453A, 4x eth integrated) I faced really strange issue that one - and only one interface is not renamed to enpXs0, but left with eth1/eth2 name. This of course breaks avahi and other configuration options that rely on interface name.

    OMV is installed on top of debian (since wanted to have OMV running on LVM for flexibility)


    Also there is no autodetect of wire plugged into the eth port.


    How to get it working properly?

  • macom

    Approved the thread.
  • Right now I have only one interface in use, but would like to have it all working, and there are plans for bonding.


    Followed this https://docs.openmediavault.or…stallation/on_debian.html and Install OMV7 on Debian 12 (Bookworm)


    By rebuild, you mean remove and install it once again (OMV), or total debian remove and install from scratch?

    Ideally it would be to repair rather than reinstalling without knowing the reason and potentially have the same issue in the future.

  • For a few reboots, it looked like I solved the issue. I've even configured all of 4 interfaes in OMV web UI. At least there are no issues with mixed ethX and enpX now. Currently I see only enpX or ethX.

    Unfortunately, after few reboots, interfaces are up only after I execute dhclient.


    I did mdadm test of renamed and eth2 interfaces gives the clue that maybe there is some persistent database for devices that introduces the issues.


    So found and fired systemd-hwdb update, also removed /lib/udev/hwdb.bin and after system restart I see no issues with ethX mixing with enpX interface names.

    • Official Post

    Here's something to keep in your back pocket:

    We ran into another issue with predictive naming when building R-PI's. It was solved by nailing down the wired interface name with a .link file.

    At /etc/systemd/network/


    Create the file 10-persistent-net.link


    #With the following contents:


    [Match]


    MACAddress=dc:a6:32:57:17:77


    [Link]


    Name=eth0
    ________________________________________________

    The above is an example, with the MAC address being from the wired port on my R-PI. Substitute in the MAC address for the interface that you want to nail down. The name can be anything you like. I chose eth0, from before the time when they decided to help us out with predictive naming.

    It takes a reboot to activate it.

    The reason why I mentioned, "would you be willing to rebuild" is because OMV writes interface names to it's configuration during the build. I don't know if those entries are permanent, updated later, etc. So,, it would be best to nail down interface names before the build.

    I haven't experimented with a file for multiple interfaces. However, this file can be elaborate if you want to set names for more than one interface. Guidance on how to do that is -> here.

  • Thank you for the suggestion, but I'd like to solve the issue rather than making a workaround (for now :D)


    After many reboots later (all done on the same machine, one instance on SSD, second on 3HDD raid1):

    • First instance of OMV7 SSD disk (by OMV7 installer, directly on the disk, ext4 partition):
      • on this system I see no such issue, I can reboot, adjust network interface preferences and there is no "eth1" naming issue. WOL, MTU adjustments works as expected without any issues.
    • Second instance of OMV7 (installed on top of debian, raid1 with 3 HDDS, lvm and btrfs for the root filesystem)
      • the name enp6s0 is stable (tested with many reboots), but as soon as I enable WOL (by the web UI), then after reboot the eth1 name appears. (setting MTU also triggers this behavior)

    How do I diagnose the issue further?

    • Official Post
    • Second instance of OMV7 (installed on top of debian, raid1 with 3 HDDS, lvm and btrfs for the root filesystem)
      • the name enp6s0 is stable (tested with many reboots), but as soon as I enable WOL (by the web UI), then after reboot the eth1 name appears. (setting MTU also triggers this behavior)

    At the final end the network configuration is generated from netplan for systemd-networkd. If there is a problem with WOL, you need to have a look in this area.

  • Where precisely I should look?


    There is a file /etc/netplan/20-openmediavault-enp6s0.yaml. If there is wakeonlan: true (modified by web UI), then after reboot, the eth1 appears. After that, if I manually modify this to false and do the restart, then it goes back to enp6s0 (of course web UI has wrong state, but it's normal in this case)

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!