Hi!

I have this little script in /usr/local/etc/rc.d to start, stop and
restart a daemon: adac.sh

#!/bin/sh

case "$1" in
    start)
        echo -n ' adac'
        /usr/local/sbin/adac 4444 > /dev/null &
        ;;
    stop)
        /bin/kill `/bin/cat /var/run/adac.pid 2> /dev/null` 2> /dev/null
        /bin/rm -f /var/run/adac.pid
        ;;
    restart)
        /bin/kill `/bin/cat /var/run/adac.pid 2> /dev/null` 2> /dev/null
        /bin/rm -f /var/run/adac.pid
        sleep 5
        /usr/local/sbin/adac 4444 & > /dev/null
        ;;
    *)
        echo ""
        echo "Usage: adac.sh {start|stop|restart}"
        echo ""
        exit 64
        ;;
esac

Then I did put this in roots crontab:
10 0 * * * /usr/local/etc/rc.d/adac.sh restart

The adac-daemon is restarted, but everytime the job runs it leaves a
sh-zombie from the cron-job. By killing the cron-job, the sh-zombie
disappears (as it should).

Do anyone know why this is happening?

Thanks in advance!

Best regards,
Paul


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-questions" in the body of the message

Reply via email to