Setup von geräten, die nicht mit ethtool wollen funktioniert jetzt auch

git-svn-id: svn://svn.compuextreme.de/Viitor/V962/Viitor_sysvinit@5223 504e572c-2e33-0410-9681-be2bf7408885
This commit is contained in:
kueller 2010-01-26 14:19:58 +00:00
parent 4cb716afbe
commit 92d35e26ca

View File

@ -111,22 +111,27 @@ case "$1" in
ifconfig $DEVNAME up ifconfig $DEVNAME up
WAITTIME=7 WAITTIME=7
ZAHLER=0 ZAHLER=0
while [ ${ZAHLER} -le ${WAITTIME} ]; do if ! ethtool $DEVNAME|grep -q "No data available"; then
if [ ! `ethtool $DEVNAME|grep Link|awk '{print $3}'` == "yes" ]; then while [ ${ZAHLER} -le ${WAITTIME} ]; do
(( ZAHLER++ )) if [ ! `ethtool $DEVNAME|grep Link|awk '{print $3}'` == "yes" ]; then
else (( ZAHLER++ ))
break else
fi break
sleep 1 fi
done sleep 1
if [ "`ethtool $DEVNAME|grep Link|awk '{print $3}'`" == "yes" ]; then done
/sbin/if_up $DEVNAME if [ `ethtool $DEVNAME|grep Link|awk '{print $3}'` == "yes" ]; then
touch /var/run/net_up /sbin/if_up $DEVNAME
fi touch /var/run/net_up
else fi
/sbin/if_up $DEVNAME else
touch /var/run/net_up /sbin/if_up $DEVNAME
fi touch /var/run/net_up
fi
else
/sbin/if_up $DEVNAME
touch /var/run/net_up
fi
done done
if [ ! -f /var/run/net_up ] && [ -f /etc/nsswitch.default ]; then if [ ! -f /var/run/net_up ] && [ -f /etc/nsswitch.default ]; then
cp /etc/nsswitch.files /etc/nsswitch.conf cp /etc/nsswitch.files /etc/nsswitch.conf