View Single Post

   
  #2 (permalink)  
Old 02-20-2008, 08:49 PM
Mike
 
Posts: n/a
Default Re: Changing network interfaces - eth0 / eth1

trryhend@gmail.com wrote:
> My interfaces seem to have swapped and not sure why. I have a PCI
> wireless card and an onboard ethernet device. They have previously
> been eth0-ethernet & eth1-wireless-wifi0, but when I just now booted,
> I see that they have swapped.
> Why would this happen? How can I stop it from happening in the
> future?


>From http://www.puresimplicity.net/~twinreverb/linux/config/

config.html

NEW: Assigning device nodes to network cards using Udev
Slackware 10.2 and after started using the udev daemon.
Basically, this loads modules and assigns their device node in /dev
automatically. However, sometimes you want a specific network card to
be assigned to a specific device node. In which case, if you look in /
etc/udev/rules.d/network-devices.rules, you will see:

#KERNEL=="eth?", SYSFS{address}=="00:0f:7b:4b:47:17", NAME="eth0"
#KERNEL=="eth?", SYSFS{address}=="00:0f:35:3c:92:cb", NAME="eth1"

Basically, this is where udev put a helpful configuration. I
detected two network cards, and assigned them, but included a
configuration to set which device node they get assigned to. Like
when I booted, my wireless card was eth0, and my ethernet card was
eth1. In the configuration above, however, if I uncomment it, this
would make my wireless card eth1 and my ethernet card eth0. What you
need to do if you are not sure is look at the MAC addresses of the
ethernet cards using a command like this:

KERNEL=="eth?", SYSFS{address}=="MAC ADDRESS", NAME="DEVICE NODE"

Reply With Quote