You are not logged in.

#1 2005-12-22 07:58:07

epo
Member
From: Romania , Iasi
Registered: 2005-06-06
Posts: 20

how to swap eth0<->eth1 with testingudev rules[SOLVED

Hi,

I want to use the udev in testing because my ML-1710P works just out of the box. Of course there is one problem ... I have two network cards and they are recognized by kernel as eth0 the one that uses 8139too (a Realtek I belive) and as eth1 the one that uses tulip. I need to swap their names because I use the tulip one for internet (my ISP uses MAC address for validation)
Previously I had in /etc/modprobe.conf

alias eth0 tulip
alias eth1 8139too

I already tried

KERNEL="eth*", SYSFS{address}="xx-xx-xx-xx-xx-xx", NAME="eth1"
KERNEL="eth*", SYSFS{address}="xx-xx-xx-xx-xx-xx", NAME="eth0"

in a file /etc/udev/rules.d/00_my.rules with correct MAC address (and lines order swapped also), but it won't work.
Any ideea how to do this?

PS: I have MOD_AUTOLOAD="yes" in /etc/rc.conf

Offline

#2 2005-12-22 08:49:56

Moo-Crumpus
Member
From: Hessen / Germany
Registered: 2003-12-01
Posts: 1,487

Re: how to swap eth0<->eth1 with testingudev rules[SOLVED

I would add the modules to the modules section in rc.conf, in the order you need them to be loaded. It does not change the autoload function, but this modules are loaded just before autoloader starts. So here is a good point to touch the system. In the end, it does what your old modprobe.conf entries did.
The first one will allways be eth0 etc.


Frumpus addict
[mu'.krum.pus], [frum.pus]

Offline

#3 2005-12-22 09:03:41

epo
Member
From: Romania , Iasi
Registered: 2005-06-06
Posts: 20

Re: how to swap eth0<->eth1 with testingudev rules[SOLVED

Thx,

Will try that as soon as I get home. I hope it works (it makes sense anyway).

Offline

#4 2005-12-22 19:21:31

epo
Member
From: Romania , Iasi
Registered: 2005-06-06
Posts: 20

Re: how to swap eth0<->eth1 with testingudev rules[SOLVED

Thx again Moo-Crumpus,

I did what you suggested and it works.

Offline

#5 2005-12-22 23:32:51

Moo-Crumpus
Member
From: Hessen / Germany
Registered: 2003-12-01
Posts: 1,487

Re: how to swap eth0<->eth1 with testingudev rules[SOLVED

pleasure smile


Frumpus addict
[mu'.krum.pus], [frum.pus]

Offline

Board footer

Powered by FluxBB