Context for newbies: Linux refers to network adapters (wifi cards, ethernet cards, etc.) by so called “interfaces”. For the longest time, the interface names were assigned based on the type of device and the order in which the system discovered it. So, eth0, eth1, wlan0, and wwan0 are all possible interface names. This, however, can be an issue: “the order in which the system discovered it” is not deterministic, which means hardware can switch interface names across reboots. This can be a real issue for things like servers that rely on interface names staying the same.

The solution to this issue is to assign custom names based on MAC address. The MAC address is hardcoded into the network adaptor, and will not change. (There are other ways to do this as well, such as setting udev rules).

Redhat, however, found this solution too simple and instead devised their own scheme for assigning network interface names. It fails at solving the problem it was created to solve while making it much harder to type and remember interface names.

To disable predictable interface naming and switch back to the old scheme, add net.ifnames=0 and biosdevname=0 to your boot paramets.

The template for this meme is called “stop doing math”.

  • laurelraven@lemmy.blahaj.zone
    link
    fedilink
    arrow-up
    3
    arrow-down
    3
    ·
    4 months ago

    Yes, because everyone has need of this solution, and wants to have to copy and paste interface names every time they need to touch them, rather than having deterministic naming be an option to enable for those who actually need it…

    • suction@lemmy.world
      link
      fedilink
      arrow-up
      1
      arrow-down
      3
      ·
      4 months ago

      You know Linux isn’t just used by nerdy kids cosplaying as Mr Robot, right?

      • laurelraven@lemmy.blahaj.zone
        link
        fedilink
        arrow-up
        3
        ·
        edit-2
        4 months ago

        You know Linux isn’t just used by enterprise sysadmins, right?

        And even speaking as an enterprise sysadmin myself, I’ve not had need or use for deterministic interface naming once in my career. I have no clue how common that is, but most of the servers, both physical and virtual, that I’ve worked on only had one Ethernet port connected.

        I see the purpose of this, but don’t see a reason why it should be the default, or why it couldn’t have been implemented like HHD/SSD UUIDs where the old dev names were left intact for easy use outside of fstab and the like where consistency could become a problem

        ETA: you also seemed to miss the part of my initial reply to you about it being something that can be enabled by those who need it… And if you’re going to say that the enterprise professionals who need it shouldn’t have to turn it on every time they spin up a system, I’ll remind you that enterprise admins working at that level where they’re setting up enough servers for that to be a hassle are probably using orchestration like Ansible, Chef, or Puppet, and can just add that into their configs once