Switch to Legacy Interface Names

This is an old revision of the document!


Switch to Legacy Interface Names

Disable new naming

Edit /etc/default/grub:

vim /etc/default/grub

Add net.ifnames=0 at the end of GRUB_CMDLINE_LINUX=“

It should look like this:

GRUB_TERMINAL_OUTPUT="console"
GRUB_CMDLINE_LINUX="biosdevname=0 crashkernel=auto nomodeset rd.auto=1 consoleblank=0 nouveau.modeset=0 rd.driver.blacklist=nouveau plymouth.ignore-udev net.ifnames=0"
GRUB_DISABLE_RECOVERY="true"

Create a new grub config

grub2-mkconfig -o /boot/grub2/grub.cfg

Create persistent-net rule in udev

Edit the file /etc/udev/rules.d/70-persistent-net.rules like (the file porbably doesnt exist):

vim /etc/udev/rules.d/70-persistent-net.rules

and add one line per interface like this:

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="HH:HH:HH:HH:HH:HH", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"
where HH:HH:HH:HH:HH:HH is the MAC Address of that interface.

Rename network scripts

Find the interface files here /etc/sysconfig/network-scripts and move them to their new names, for each script you need to edit it and change the device name. Example:

mv /etc/sysconfig/network-scripts/ifcfg-en0s0p0 /etc/sysconfig/network-scripts/ifcfg-eth0

/home/www/sites/esgr.in/wiki/data/attic/systems/legacy_interface_names.1515671987.txt.gz · Last modified: 2018/01/11 11:59 by eServices Greece