On Thu, 23 Dec 2004, Jason Joines wrote:
I'm trying to get SuSE 9.2 Pro installed on a machine with two NIC's. It was previously running 9.1 and whichever NIC I configured first got eth0. That doesn't work with 9.2. I'm not sure how it's choosing which one gets eth0 but it seems to always picke the one that should be eth1.
I tried disabling the NIC I want to be eth1 in the BIOS and then re-installing. After the install, the one I wanted to have eth0 did have it. Then I re-enabled the other NIC and when the box came up it had swapped eth0 and eth1 again.
Seems modprobe.conf has replaced modules.conf and says to make changes in modprobe.conf.local. I tried adding "alias eth0 e100" (the NIC that should be eth0 is an Intel using e100 and the one that should be eth1 is a BroadCom using something else) as the only line in modprobe.conf.local but that did not work. The first couple of lines in modprobe.conf are "install eth0 /bin/true" and "install eth1 /bin/true". I've read the modprobe.conf man page but still have not idea what those lines are doing and there are no "alias eth0 ..." or "alias eth1 ..." lines anywhere.
What does "install eth0 /bin/true" do and how can I specify which NIC gets eth0 and which gets eth1?
Short version: you can't rely on the order in which the kernel (or hotplug!) recognizes and initializes the cards, therefore you cannot rely on which is eth0 and which is eth1. This has been true since the very earliest versions of the kernel (although the interface recognition has been observably static, that is purely accidental!). Thus, SuSE 9.2 and others use the MAC address to uniquely identify interfaces (yes, yes, I know MACs aren't necessarily unique either, they are "unique enough"). I suggest you look at doing something like this: mac=$(/sbin/ifconfig "$iface" | sed -n -e '/^.*HWaddr \([:[:xdigit:]]*\).*/{s//\1/;y/ABCDEF/abcdef/;p;q;}') WHich is taken verbatim from get-mac-address.sh on my Debian box. Note my MUA broke the long line, there is a space after HWaddr. -- Carpe diem - Seize the day. Carp in denim - There's a fish in my pants! Jon Nelson <jnelson-suse@jamponi.net>