network interfaces exchanged
Andreas Sindermann
sinder at thp.Uni-Koeln.DE
Fri May 19 14:53:22 CEST 2006
Henning Glawe writes:
> On Fri, May 19, 2006 at 10:49:11AM +0200, Andreas Sindermann wrote:
> > during the fai-installation the nfsroot-kernel sees the two network
> > interfaces eth0 and eth1 in a different order than the kernel used
> > during normal operation. The effect is that when booting from harddisk
> > no network is available. How does one care about this usually?
>
> use something like ifrename or nameif to rename the interfaces by looking at
> the MAC address. In testing/unstable, this functionality is provided by
> udev.
This seems to be exactly what I'm looking for. Unfortunately when
simply creating the /etc/mactab file
(in <fai>/scripts/FAIBASE/30-interface) with the following few lines
the installed system doesn't recognize that it should use 'nameif' to
reorder the interfaces. Does one have to create explicitely a
new boot-script or something in /etc/network/if-pre-up.d?
(this is on an Ubuntu dapper system) Or is there something something
in the /etc/udev/ region that needs to be changed?
# FAI Ubuntu kernel thinks something different than the normal Ubuntu
# kernel about the order of the network interfaces. So use nameif(1)
# which reads /etc/mactab for defined order of interfaces.
if [ -f $LOGDIR/dhclient.log ]; then
myif=`grep Listening $LOGDIR/dhclient.log | awk -F/ '{print $2}'`
mymac=`grep Listening $LOGDIR/dhclient.log | awk -F/ '{print $3}'`
echo "$myif $mymac" > $target/etc/mactab
fi
Andreas
--
Dr. Andreas Sindermann fon: +49 (221) 470-4201
Institut fuer Theoretische Physik fax: +49 (221) 470-5159
Universitaet zu Koeln
Zuelpicher Str. 77 mailto:sinder at thp.Uni-Koeln.DE
D-50937 Koeln, Germany http://www.thp.uni-koeln.de/~sinder
More information about the linux-fai
mailing list