LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Suddenly NIC names change (https://www.linuxquestions.org/questions/linux-networking-3/suddenly-nic-names-change-594308/)

ivanatora 10-24-2007 03:19 PM

Suddenly NIC names change
 
Hello,
I have two lan cards:
1) integrated RTL8169 Gbit
2) external PCI RTL8139
They are both compiled as modules for the kernel 2.6.21.5
After a restart it happened their names (eth0, eth1) are changed. Why is that?
Does it matters which module loads first? If yes - how to check that?

Thanks!

Brian1 10-24-2007 05:19 PM

Modules can usually be define in /etc/modprobe.conf file. Define an alias for eth0 and the module for it to use. Same for eth1. Not sure if it has an effect based on PCI interrupt order. If certain changes were made in the kernel on the pci then it may have this effect.

Brian

MQMan 10-24-2007 11:59 PM

Quote:

Originally Posted by Brian1 (Post 2935626)
Modules can usually be define in /etc/modprobe.conf file.

Code:

# The use of this config file is deprecated.
# Instead, create files in the /etc/modprobe.d/ directory
# containing modprobe options.

Or you can use udev, and set a rule which will always assign the interface based on the MAC.

Cheers.

ivanatora 10-25-2007 07:05 AM

Neccesarry rules found in /etc/udev/rules.d/network-devices.rules !
I just had to uncomment the right lines:
KERNEL=="eth?", SYSFS{address}=="00:13:8f:ea:f0:1e", NAME="eth1"
KERNEL=="eth?", SYSFS{address}=="00:19:e0:0e:e8:7d", NAME="eth0"


All times are GMT -5. The time now is 05:43 AM.