Dear managers!
Thank you for your responses. In particular I wish to thank
John P Speno <speno_at_isc.upenn.edu>
who helped me getting my dhcpd startup script running. Placing 'nohup'
before the command invoking dhcpd does the trick (for some obscure
reasons). The output generated by dhcpd during boot is then redirected
to '/nohup.out'. For your convenience, the updated script is included at
the end of this message.
Regards
Peter
Original message follows:
I'm using the ISC dhcp server 2.0 on one of my machines. It runs fine
but it won't startup during boot. The startup script in /sbin/init.d
(linked to /sbin/rc3.d, of course) invoked during boot shows no abnormal
behaviour. There is a message on the console indicating the server is up
and running (the same message appears in daemon.log) but there's no
process for dhcpd subsequently. When I invoke the startup script
manually as super user then dhcpd starts and remains active.
What could be missing?
-snip------------------------------------------------------------------
#!/sbin/sh
PATH=/sbin:/usr/sbin:/usr/bin
export PATH
case "$1" in
'start')
if [ -f /usr/sbin/dhcpd ]; then
nohup /usr/sbin/dhcpd # <-- this one works as expected!
echo "dhcp service started"
else
echo "Unable to start dhcp service -- no /usr/sbin/dhcpd"
exit 1
fi
;;
'stop')
pid=`cat /var/run/dhcpd.pid`
if [ "X$pid" != "X" ]; then
/bin/kill $pid
else
echo "No pid for dhcp service found"
exit 1
fi
;;
'restart')
/sbin/init.d/dhcpd stop
if [ $? -ne 0 ]; then
echo " -- Could not find running dhcpd - attempting to restart..."
fi
sleep 2
/sbin/init.d/dhcpd start
;;
*)
echo "usage: $0 {start|stop|restart}"
;;
esac
-snip------------------------------------------------------------------
--
Dipl.-Phys. Rolf-Peter Kienzle (Systems Manager)
Dept. of Remote Sensing and Land Information Systems
University of Freiburg, D-79085 Freiburg, Germany
Tel/Fax +49 761 203 8643/3701 e-mail: kienzlep_at_uni-freiburg.de
Received on Wed Aug 02 2000 - 20:24:54 NZST