Does anyone else experience erratic behaviour with system startup
scripts in /sbin/rc3.d? On some of my systems, running 4.0F pk2, some
daemons *claim* to be started (the message goes by on the console) but
they don't continue to run. It doesn't seem to happen with system-provided
scripts, but I don't see anything wrong with the scripts which fail. For
example the script we have to start the ISC dhcp 2.0 server is:
#!/sbin/sh
PATH=/sbin:/usr/sbin:/usr/bin
export PATH
case "$1" in
'start')
if /usr/sbin/dhcpd; then
echo "Started dhcpd"
else
echo "Couldn't start dhcpd"
fi
;;
'stop')
if [ -r /var/run/dhcpd.pid ]; then
kill `cat /var/run/dhcpd.pid`
else
echo "ERROR: cannot find /var/run/dhcpd.pid to kill dhcpd."
fi
;;
*)
echo "usage: $0 {start|stop}"
;;
esac
Owner bin.bin, permissions 750, linked as /sbin/rc3.d/S82dhcpd ->
/sbin/init.d/dhcpd, yet this failed to start in a recent reboot.
Another script which shows this behaviour is that for the "free"
Altavista search engine, which fails to start *almost* every time; and
this one is a Digital-provided script. Running the script manually
after startup makes it run normally. Some startup scripts, such as
those for ssh, never fail.
Any ideas? My only thought is peppering the scripts with sleep
statements to let the daemons start fully before the script exits, but
it does seem like a rather "voodoo" kind of solution...
Thanks,
Graham Allan
Physics, University of Minnesota
Received on Wed Feb 23 2000 - 18:01:45 NZDT