>
> > If it runs out of cron it runs for just milli- seconds - other wise it is
> in the proc table
>
> Assuming of course that you don't end up with hundreds of spawned cron jons.
<rocket science>
Run the following fc.sh script from cron every hour
#!/bin/sh
# usage: fc.sh [now]
# Any argument will bypass the random sleep period
if /usr/bin/pgrep -x freshclam >/dev/null 2>&1; then
echo 'Killing a stale instance of freshclam.' |\
/usr/bin/mailx -s '[mailhost05] freshclam error' [EMAIL PROTECTED]
/usr/bin/pkill freshclam || echo 'Unable to kill freshclam'
fi
# if no arg to script, sleep random <= 1800 seconds
if [ -z "$1" ]; then
/usr/bin/bash -c '/usr/bin/sleep $[ RANDOM % 1800 ]'
fi
/usr/local/bin/freshclam --quiet --daemon-notify=/usr/local/etc/clamd.conf
>/dev/null 2>&1
# end of script
</rocket science>
dp
_______________________________________________
http://lurker.clamav.net/list/clamav-users.html