Instead of completely disabling the renaming you can override it to give your interfaces your own custom names. That keeps the static naming, but gives you a name you can remember and type in.
The existing naming system (/lib/udev/rules.d/80-net-setup-link.rules
) only renames an interface if it hasn't already been given a name. So you can add your own rules at a higher priority in /etc/udev/rules.d
which names the interfaces in your own way, which then stops the default system from naming those interfaces.
I have the file 70-wifi.rules
in my system which names the interfaces according to the network they are connected to:
SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="00:0f:00:4a:c4:c9", NAME="wifi-root"
SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="00:19:86:31:dd:b7", NAME="wifi-main"
SUBSYSTEM=="net", ACTION=="add", ATTR{address}=="38:2c:4a:48:27:49", NAME="wifi-local"
It's keyed by the MAC address of the interface, and results in:
$ ip link
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: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
link/ether 3c:d9:2b:73:ad:5d brd ff:ff:ff:ff:ff:ff
15: wifi-main: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DORMANT group default qlen 1000
link/ether 00:19:86:31:dd:b7 brd ff:ff:ff:ff:ff:ff
16: wifi-local: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DORMANT group default qlen 1000
link/ether 38:2c:4a:48:27:49 brd ff:ff:ff:ff:ff:ff
17: wifi-root: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP mode DORMANT group default qlen 1000
link/ether 00:0f:00:4a:c4:c9 brd ff:ff:ff:ff:ff:ff
You could rename them wlan0, wlan1, etc. The beauty of this method is you get the names you want, and you benefit from static network interface naming. So the interfaces will always be named the same thing.