Score:0

Drivers renaming network interfaces - is there a way to prevent it?

ba flag

This is 32-bit Ubuntu 18.04.5 LTS

The following is output from dmesg | grep "renamed from".

[    6.952855] r8169 0000:01:00.0 eno1: renamed from eth0
[    6.973957] e100 0000:05:00.0 enp5s0: renamed from eth1
[   22.375269] ath9k_htc 1-2:1.0 wlx6466b31c83ef: renamed from wlan0

I am OK with eno1 and enp5s0, but wlx6466b31c83ef is getting a little ridiculous. Is there a way to prevent drivers renaming the interfaces?

Jad avatar
br flag
Jad
can you take a look at https://askubuntu.com/questions/767786/changing-network-interfaces-name-ubuntu-16-04#answer-767796 and see if this works for you (at least the GRUB part)?
circl avatar
ba flag
Oh yes! The GRUB Linux parameter worked.
cn flag
also interesting https://www.freedesktop.org/wiki/Software/systemd/PredictableNetworkInterfaceNames/ and https://wiki.debian.org/NetworkInterfaceNames
cn flag
your 3rd one seems to fall back to "Names incorporating the interfaces's MAC address" so I would assume your BIOS is giving off wrong info (Names incorporating Firmware/BIOS provided index numbers for on-board devices (example: eno1), Names incorporating Firmware/BIOS provided PCI Express hotplug slot index numbers (example: ens1), Names incorporating physical/geographical location of the connector of the hardware (example: enp2s0) come before that.
circl avatar
ba flag
Ah, since the now `wlan0` is a USB WiFi adapter, the first criteria it fits is by MAC address.
Score:0
br flag
Jad

as per the first part of this answer from another thread:

Step 1: Disable the default Firmware inherited names.

Edit your /etc/default/grub changing the line from

GRUB_CMDLINE_LINUX=""

to

GRUB_CMDLINE_LINUX="net.ifnames=0 biosdevname=0"

and, finally run as root:

$ sudo update-grub

and reboot your system.

$ sudo reboot

(glad it worked)

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.