which NIC is which
I'm building routers. It's difficult to tell in advance which NIC will be assigned eth0 and which will assigned eth1 when using two NICs. Ping testing usually clears up this simple problem.
The identification problem gets worse when adding a third NIC, after sorting out the first two NICs. Frequently the eth0 or eth1 assignments for the first two NICs change.
Of course adding a fourth and fifth NIC multiplies the identification problem. Yes, some of my routers are supporting five network segments.
My question is, what's the algorithm for assigning Ethernet designations? I know it not placement order in the PCI bus, and I know its not the NIC data-link address.
So what is it?
Thanks ...John
Signature · 8 lines
John Telford - Owner JohnTelford.com LLC 503-292-6865 - fax:503-292-3094 [email protected] - www.johntelford.com _______________________________________________ LARTC mailing list / [email protected] http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Quoted 8 lines · John Telford
I'm building routers. It's difficult to tell in advance which NIC will be assigned eth0 and which will assigned eth1 when using two NICs. Ping testing usually clears up this simple problem.
The identification problem gets worse when adding a third NIC, after sorting out the first two NICs. Frequently the eth0 or eth1 assignments for the first two NICs change.
Quoted 8 lines
Of course adding a fourth and fifth NIC multiplies the identification problem. Yes, some of my routers are supporting five network segments.
My question is, what's the algorithm for assigning Ethernet designations? I know it not placement order in the PCI bus, and I know its not the NIC data-link address.
So what is it?
Almost random. However, there's some evidence to suggest:
order of probing of device drivers
order of I/O addresses
Unfortunately, in systems with identical cards that are configured using plug-and-play methods such as those used by PCI random is the best shot you have...
Doei, Arthur.
Signature · 7 lines
/\ / | [email protected] | Work like you don't need the money /__\ / | A friend is someone with whom | Love like you have never been hurt / \/__ | you can dare to be yourself | Dance like there's nobody watching _______________________________________________ LARTC mailing list / [email protected] http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Quoted 5 lines · Arthur van Leeuwen
Unfortunately, in systems with identical cards that are configured using plug-and-play methods such as those used by PCI random is the best shot you have...
'Deterministic' is more accurate. It seems to be random, on first boot. But it will almost never change after that unless you make hardware changes, in my experience.
Signature · 7 lines
Michael T. Babcock CTO, FibreSpeed Ltd. _______________________________________________ LARTC mailing list / [email protected] http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Quoted 10 lines · Michael T. Babcock
Quoted 5 lines · Arthur van Leeuwen
Unfortunately, in systems with identical cards that are configured using plug-and-play methods such as those used by PCI random is the best shot you have...
'Deterministic' is more accurate. It seems to be random, on first boot. But it will almost never change after that unless you make hardware changes, in my experience.
Not in mine. Every time the PCI bus settings (can't recall the name right now, have been playing with a fixed hardware platform for quite a while) get reset there will probably be a different assignation. Yeah, it'll probably be deterministic *somehow*, but you'll be hard pressed to come up with any rules.
Doei, Arthur.
Signature · 7 lines
/\ / | [email protected] | Work like you don't need the money /__\ / | A friend is someone with whom | Love like you have never been hurt / \/__ | you can dare to be yourself | Dance like there's nobody watching _______________________________________________ LARTC mailing list / [email protected] http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Quoted 7 lines · John Telford
I'm building routers. It's difficult to tell in advance which NIC will be assigned eth0 and which will assigned eth1 when using two NICs. Ping testing usually clears up this simple problem.
The identification problem gets worse when adding a third NIC, after sorting out the first two NICs. Frequently the eth0 or eth1 assignments for the first two NICs change.
There are tricks to configure based on the MAC address of your interface instead of on its place in the probe. Perhaps googling on that will help.
Regards,
bert
Signature · 6 lines
http://www.PowerDNS.com Versatile DNS Software & Services http://www.tk the dot in .tk http://lartc.org Linux Advanced Routing & Traffic Control HOWTO _______________________________________________ LARTC mailing list / [email protected] http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Thus spake bert hubert:
Quoted 11 lines · John Telford
Quoted 7 lines
I'm building routers. It's difficult to tell in advance which NIC will be assigned eth0 and which will assigned eth1 when using two NICs. Ping testing usually clears up this simple problem.
The identification problem gets worse when adding a third NIC, after sorting out the first two NICs. Frequently the eth0 or eth1 assignments for the first two NICs change.
There are tricks to configure based on the MAC address of your interface instead of on its place in the probe. Perhaps googling on that will help.
A script to rename interfaces with "ip link ... set name ..." after modprobe according to their hw addresses should suffice.
I never tried this because in my experience order of detection was always consistant between reboots assuming there are no hardware chasnges.
_______________________________________________
LARTC mailing list / [email protected]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
Quoted 5 lines · Vladimir B. Savkin
A script to rename interfaces with "ip link ... set name ..." after modprobe according to their hw addresses should suffice.
I never tried this because in my experience order of detection was always consistant between reboots assuming there are no hardware chasnges.
If you turn on APIC you are in for a surprise I gather :-)
Regards,
bert
Signature · 6 lines
http://www.PowerDNS.com Versatile DNS Software & Services http://www.tk the dot in .tk http://lartc.org Linux Advanced Routing & Traffic Control HOWTO _______________________________________________ LARTC mailing list / [email protected] http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/