# stop udev from switching names (choose old behaviour instead

## kokyu

Hey all,

since recently, the systemd/udev developers decided to use enp1s0 instead of eth0, or where-ever your ethernet card is plugged into.

This all seems ignorable when it comes down to desktop hardware, but I just installed Gentoo on one of your nodes in the data center

which now have a name as enp7s0f0 and enp7s0f1 which is by far no fun if you want to deploy some software on every node that were used to have eth0 for internal and eth1 for external traffic but now the interface name can vary almost like anything.

So is there a way to revert this back, such as adding a udev rules entry to set this explicitely back to eth0/eth1, something homogenous ?

I tried adding a 70-mynames.rules into /etc/udev/rules.d/ and rebooted. but it seemed like udev ignored my file.

Maybe I mispelled it or it should look different now?

This is the contents:

KERNEL=="eth?", SYSFS{address}=="00:25:90:2b:8e:34", NAME="eth0"

KERNEL=="eth?", SYSFS{address}=="00:25:90:2b:8e:35", NAME="eth1"

Best regards.

----------

## dmpogo

 *kokyu wrote:*   

> Hey all,
> 
> since recently, the systemd/udev developers decided to use enp1s0 instead of eth0, or where-ever your ethernet card is plugged into.
> 
> This all seems ignorable when it comes down to desktop hardware, but I just installed Gentoo on one of your nodes in the data center
> ...

 

yes, create a symlink

/etc/udev/rules.d/80-net-name-slot.rules -> /dev/nullLast edited by dmpogo on Thu Jul 04, 2013 2:54 pm; edited 1 time in total

----------

## Hu

That file can also be empty to disable the behavior.  OP: you should read your Gentoo news before upgrading.  Specifically, look at news item Upgrading udev to version >=200, which discusses in considerable detail how to override the stupid defaults that the systemd-udevd maintainers decided to use (and which the Gentoo udev maintainers decided to pass through).

----------

