Umstellung auf den neuen dhcp client "dhcpcd"

git-svn-id: svn://svn.compuextreme.de/Viitor/V963/Viitor_upstart@6025 504e572c-2e33-0410-9681-be2bf7408885
This commit is contained in:
kueller 2011-03-04 10:31:24 +00:00
parent 3f38c793f1
commit c82ef13b01
2 changed files with 2 additions and 8 deletions

View File

@ -40,13 +40,7 @@ if pgrep vtun >/dev/null; then
fi fi
if [ -f /etc/sysconfig/net/${DEV}.dhcp ]; then if [ -f /etc/sysconfig/net/${DEV}.dhcp ]; then
echo -n "Stopping dhclient for $DEV" echo -n "Stopping dhclient for $DEV"
DHPID=`ps -ef|grep dhclient|grep ${DEV}|awk '{print $2}'` dhcpcd -k $DEV
if [ "$DHPID" ]; then
kill $DHPID
fi
evaluate_retval
echo -n "Shutting down Interface $DEV"
ifconfig $DEV 0.0.0.0 down
evaluate_retval evaluate_retval
elif [ -f /etc/sysconfig/net/hostname.${DEV} ]; then elif [ -f /etc/sysconfig/net/hostname.${DEV} ]; then
HOST=`cat /etc/sysconfig/net/hostname.${DEV}|awk '{print $1}'` HOST=`cat /etc/sysconfig/net/hostname.${DEV}|awk '{print $1}'`

View File

@ -90,7 +90,7 @@ if [ -f /etc/sysconfig/net/${DEV}.dhcp ]; then
#only if there is a link, we will setup the interface.. #only if there is a link, we will setup the interface..
if CheckForLink ${DEV}; then if CheckForLink ${DEV}; then
echo -n "Setting up ${DEV} with dhcp" echo -n "Setting up ${DEV} with dhcp"
dhclient -q ${DEV} dhcpcd -q ${DEV}
evaluate_retval evaluate_retval
else else
ifconfig ${DEV} down ifconfig ${DEV} down