If you fire up a fresh install of Ubuntu 15.10 (Wily Werewolf) you will find yourself with unfamiliar, and unfriendly network interface names. You will notice eth0
and eth1
are gone. If you see this, don’t panic! This is the new expected behavior.
This change is due to a feature of systemd called “predictable interface names”. Ubuntu 15.04 (Vivid Vervet) also had this feature, but it was disabled by default.
The advantages of having predictable interface names are that, the network interfaces won’t rename themselves on you. This can happen across installs or upgrades, and in some cases, particularly with a read-only root, across reboots.
Needless to say, if you are a firewall, having your public and private networks swapped is a big deal.
Accept the Change
In most cases, this will be the easy option and you can stop reading here
However, the cases of single NIC environments, where you have hard coded eth0
, going back to non predictable interface names may be your only agreeable option.
Getting eth0
Back
For this, you will need to set the kernel parameter net.ifnames=0
and reboot back into 2014.
Try it First
You can try this mode without making any permanent system changes. On boot, in the grub console, edit the default boot config (the one with a *
next to it, and probably called Ubuntu
). You do this by pressing e
as per the on screen instructions. You will then need to scroll down until you find a line that begins with linux
. Append the above kernel parameter to this line and press F10
.
Make it Permanent
All going well, you will want to make this permanent. The easiest way to do this is to edit your grub config and add the new parameter to the GRUB_CMDLINE_LINUX_DEFAULT
variable. Something like this:
You will then need to update your grub config:
1 % sudo update-grub
2 Generating grub configuration file ...
3 Found linux image: /boot/vmlinuz-4.2.0-16-generic
4 Found initrd image: /boot/initrd.img-4.2.0-16-generic
5 Found memtest86+ image: /memtest86+.elf
6 Found memtest86+ image: /memtest86+.bin
7 done
After the customary reboot you should be back in eth0
land.