#!/bin/sh

# added per SR 67, removed SR 10 fix as it was single nic only (leem)
((i=0))
for mod in `/sbin/discover --module ethernet`
do
echo "alias eth$i $mod" >>  /etc/modutils/aliases
((i=$i+1))
done

/sbin/update-modules

# DHCP? Figure out our DNS name and name the box...

if ( grep dhcp /etc/network/interfaces 1> /dev/null )
then
	IP=`ifconfig eth0 | grep "inet addr" | cut -d: -f2 | cut -d' ' -f1`
	NAME=`host $IP | grep "Name:" | awk '{print $2}'`
	if ( echo $NAME | grep hp.com 1> /dev/null )
	then
		echo $NAME | tee /etc/hostname | xargs hostname
	fi
fi

# End of standard LinuxCOE stuff...  
 
