Skip to contentSkip to conversation

eth interface enumeration order

DISCUSSION Victor Secarin 4 participants 4 messages Aug 23, 2006

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

VERSION
With kernel 2.4.33.1:
HARDWARE
I have a server with two eepro100 and one e1000 interfaces
BEHAVIOR
When the kernel boots the drivers report (/var/log/messages) the interfaces they find and what they are named (eth0, eth1, eth2)
1. With the drivers configured monolithically in the kernel:
e1000 reports eth0 and then eepro100 reports eth1 and eth2
2. With the drivers configured as modules:
eepro100 reports eth0 and eth1 and then e1000 reports eth2
PROBLEM
1. On a red hat distribution, different interfaces may have different configuration scripts, which assign IP addresses and more, and the scripts are identified by the ethx name.
2. It is necessary to control which interface becomes eth0 as various programs use the MAC address of eth0 to identify the computer. In my case that is "lmhostid" and all the FLEXlm software, as I run a license server on that machine.

Thank you for taking the time to read this.
yours truly,
Victor Secarin

#1 lore raw
Quoted 6 lines · Victor Secarin

VERSION
With kernel 2.4.33.1:
HARDWARE
I have a server with two eepro100 and one e1000 interfaces
BEHAVIOR
When the kernel boots the drivers report (/var/log/messages) the interfaces they find and what they are named (eth0, eth1, eth2)

Quoted 8 lines

1. With the drivers configured monolithically in the kernel:
e1000 reports eth0 and then eepro100 reports eth1 and eth2
2. With the drivers configured as modules:
eepro100 reports eth0 and eth1 and then e1000 reports eth2
PROBLEM
1. On a red hat distribution, different interfaces may have different configuration scripts, which assign IP addresses and more, and the scripts are identified by the ethx name.
2. It is necessary to control which interface becomes eth0 as various programs use the MAC address of eth0 to identify the computer. In my case that is "lmhostid" and all the FLEXlm software, as I run a license server on that machine.

[ Please don't mail tree maintainers with this sort of question. ]

[ Try using the e100 driver instead of eepro100 ;) ]

there are several answers to this solution. First of all, you can build the e100 driver into the kernel and use e1000 as a module, at which point the in-kernel driver will always load first.

second of all, you can set alias eth0 e100 in your /etc/modules.conf and force that nic to be bound to the first interface.

other handwork includes manually installing the modules in the right order at boot time.

Cheers,

Auke

#2 lore raw
In reply to Victor Secarin
Quoted 9 lines · Victor Secarin

VERSION
With kernel 2.4.33.1:
HARDWARE
I have a server with two eepro100 and one e1000 interfaces BEHAVIOR
When the kernel boots the drivers report (/var/log/messages) the interfaces they find and what they are named (eth0, eth1, eth2)
1. With the drivers configured monolithically in the kernel:
e1000 reports eth0 and then eepro100 reports eth1 and eth2

Bus order.

Quoted 2 lines

2. With the drivers configured as modules:
eepro100 reports eth0 and eth1 and then e1000 reports eth2

Module load order.

Quoted 8 lines

PROBLEM
1. On a red hat distribution, different interfaces may have different configuration scripts, which assign IP addresses and more, and the scripts are identified by the ethx name.
2. It is necessary to control which interface becomes eth0 as various programs use the MAC address of eth0 to identify the computer. In my case that is "lmhostid" and all the FLEXlm software,
as I run a license server on that machine.

Manually load the modules in the correct order, that should solve your problems. Or use nameif to rename the network devices (on 2.6 that should be done using udev).

Erik

Signature · 2 lines
+-- Erik Mouw -- www.harddisk-recovery.com -- +31 70 370 12 90 --
| Lab address: Delftechpark 26, 2628 XH, Delft, The Netherlands
#3 lore raw
In reply to Victor Secarin
Quoted 20 lines · On Wed, 23 Aug 2006 09:52:56 -0600 Victor Secarin <[email protected]>…

VERSION
With kernel 2.4.33.1:
HARDWARE
I have a server with two eepro100 and one e1000 interfaces
BEHAVIOR
When the kernel boots the drivers report (/var/log/messages) the interfaces they find and what they are named (eth0, eth1, eth2)
1. With the drivers configured monolithically in the kernel:
e1000 reports eth0 and then eepro100 reports eth1 and eth2
2. With the drivers configured as modules:
eepro100 reports eth0 and eth1 and then e1000 reports eth2 PROBLEM
1. On a red hat distribution, different interfaces may have different configuration scripts, which assign IP addresses and more, and the scripts are identified by the ethx name.
2. It is necessary to control which interface becomes eth0 as various programs use the MAC address of eth0 to identify the computer. In my case that is "lmhostid" and all the FLEXlm software,
as I run a license server on that machine.

Quoted 3 lines

Thank you for taking the time to read this.
yours truly,
Victor Secarin

Depending on interface names and ordering is wrong, you will get burned. Modern distro's with 2.6 use udev and scripts to control naming.

For older systems, see ifrename(8)

Signature · 3 lines
Stephen Hemminger <[email protected]>

All non-trivial abstractions, to some degree, are leaky.