Crontab not working??

Thomas K. fwd at gothschlampen.com
Thu Jan 14 00:47:53 UTC 2010


On Thu, Jan 14, 2010 at 02:20:07AM +0200, Kaya Saman wrote:

Hi,

> @reboot           root    /usr/local/sbin/logwatch.pl
> 02 4 * * *     root    /usr/local/sbin/logwatch.pl

this format/syntax is only valid for the system contab.

> The interesting thing here is that it shows them as being run:
> 
> rd1# cat /var/log/cron | grep logwatch
> Jan 12 04:02:00 rd1 /usr/sbin/cron[5882]: (root) CMD 
> (root^I/usr/local/sbin/logwatch.pl)
> Jan 13 04:02:00 rd1 /usr/sbin/cron[8898]: (root) CMD 
> (root^I/usr/local/sbin/logwatch.pl)

As you can see, the command is not valid. You should at least get an
error. If the scripts do not set PATH themselvs, try setting it in the
crontab, as the default is rather minimal.

Regards
Thomas


More information about the freebsd-questions mailing list