[PATCH] patch to speed up bootpc queries
Thomas Lange
lange at informatik.Uni-Koeln.DE
Fri Jan 4 15:14:56 CET 2002
I hope the problem is solved now. In the next fai version only active
network devices are used for bootpc or dhcp queries. These are devices
which are configured to be running and have a valid IP address. This
list can be overwritten using the variable $netdevices. By now you can
also change the variable $timeout (in fai.conf) to decrease the
timeout for a bootpc call, which is default to 30 seconds.
rcS_fai:
timeout=30 # bootpc timeout
I hope this works for all of you.
Here are the details how this is implemented.
cvs diff: Diffing .
Index: subroutines
===================================================================
RCS file: /home/lange/.cvs_repository/debian/fai/lib/subroutines,v
retrieving revision 1.62
diff -r1.62 subroutines
48a49,50
> # devices that are running
> netdevices_up=`ifconfig | perl -anF'\s+' -e 'print "$F[0]\n" if $F[0];' | grep -v "^lo"`
51c53,55
< [ -n "$netdevices" ] || netdevices=`dmesg|grep "^eth.: "| awk -F: '{print $1}'|sort|uniq`
---
> [ -n "$netdevices" ] || netdevices=$netdevices_up
> netdevices_all=`dmesg|grep "^eth.: "| awk -F: '{print $1}'|sort|uniq`
>
672c676,677
< echo "Ethernet cards found: $netdevices"
---
> echo "Ethernet cards found: $netdevices_all"
> echo "Ethernet cards running: $netdevices_up"
--
Thomas
More information about the linux-fai
mailing list