Hi,
I'm in the process of upgrading our FAI installation from Lenny to Squeeze and
have run into a bit of a bug. I suspect that it is more of a Squeeze bug than a
FAI bug, but I thought that I'd check here first as the help that I have
received here is top notch :)
With some help from Michael Tautschig I'd developed a script that uses the
variable $netdevices_up to determines the mac address of the client. It then
does a search for a matching (mac address).var within
$FAI/config/class/MAC.vars to give FAI the configuration data for the install
that I wish to give. This had been working great!
In working through the upgrade to Squeeze however, this script is failing. The
problem is that with Squeeze $netdevices_up returns all devices except LO, up
or not.
get-boot-info determines $netdevices_up like so:
netdevices_up=$(ip link show up | grep "^[1-9$]" | cut -d : -f 2 | cut -d '
' -f 2 | grep -v "^lo" | sort | uniq)
And on Squeeze "ip link show up" returns this.
r...@db099:~# ip link show up
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP
qlen 100
link/ether 00:30:48:72:21:d6 brd ff:ff:ff:ff:ff:ff
3: eth1: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state
DOWN qlen 1000
link/ether 00:30:48:72:21:d7 brd ff:ff:ff:ff:ff:ff
As you can see device 3, eth1 has no cable plugged into it, thus NO-CARRIER and
state DOWN but it is still returned. On Lenny device 3, eth1 wouldn't be
returned.
I'd think this is a bug in Squeeze and that the intended behavior wasn't
intentionally changed between Lenny and Squeeze, but I do not know for sure. I
am also wondering if perhaps get-boot-info should be modified to handle this in
case Squeeze was purposely changed, or doesn't get fixed any time soon?
David Dreezer
Customer Advocate, Social Strata, Inc.