EthX naming convention. How is assigment index when I have two eth interfaeclassic naming scheme for network interfaces?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

EthX naming convention. How is assigment index when I have two eth interfaeclassic naming scheme for network interfaces?

559 Views
sebastianpszczo
Contributor I

I checked and I do not have any rules in udev to name change for eth etc. I need use that two interface and make sure that they can't change order. How should we do this in production devices when we have one WLAN device on USB in every board and we always want configure it as WLAN0

Is there problem with:

The classic naming scheme for network interfaces applied by the kernel is to simply assign names beginning with "eth" to all interfaces as they are probed by the drivers. As the driver probing is generally not predictable for modern technology this means that as soon as multiple network interfaces are available the assignment of the names is generally not fixed anymore and it might very well happen that "eth0" on one boot ends up being "eth1" on the next. This can have serious security implications...

Thank You

Labels (3)
0 Kudos
1 Reply

486 Views
b36401
NXP Employee
NXP Employee

You can assign exact names to the devices with udev rules.
You can create your own udev rules file and set the names property for the devices.
Make sure to order it before the default policy file, for example by naming it /etc/udev/rules.d/70-my-net-names.rules

Have a great day,
Victor

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos