2017-12-28 Non-predictable interface names biting me 2 years ago
While doing some upgrades on new homeserver I ran into a problem with the tun/tap network driver which is needed for virtual machines, giving the error messageDec 27 21:41:51 conway kernel: [ 266.832675] tun: Unknown symbol dev_get_valid_name (err 0)Since virtual machines are the main thing to run in this machine I needed this driver to work. Searching for solutions found the suggestion to reinstall the linux kernel image, which I did:# apt-get install --reinstall linux-image-$(uname -r) # apt-mark auto linux-image-$(uname -r)After which the system came up fine but without a network connection it seemed. This is irritating as the homeserver is in the attic and I found out the VGA screen up there does not cooperate with the new server. So another VGA screen got dragged up there to fix it. Some searching later I found the eth2 and eth3 interfaces got swapped from what I expected. These are the two mainboard interfaces, both Intel interfaces but with different chipsets. There is a /etc/udev/rules.d/70-persistent-net.rules which sets this up but it isn't working at the moment: In the system logs:[ 2.833442] udevd: Error changing net interface name eth2 to eth3: File exists [ 2.834309] udevd: could not rename interface '4' from 'eth2' to 'eth3': File exists [ 2.866356] udevd: Error changing net interface name eth3 to eth2: File exists [ 2.868197] udevd: could not rename interface '5' from 'eth3' to 'eth2': File existsMaybe different names that don't start with eth will work better to get truely persistant names as the current situation isn't very stable and reliable. After all the work the tun/tap driver works again so the virtual machines now start fine.