Cron Not Sending Mail

Glen Barber glen.j.barber at gmail.com
Mon Mar 2 19:14:20 PST 2009


On Sun, Mar 1, 2009 at 2:24 PM, APseudoUtopia <apseudoutopia at gmail.com> wrote:
[snip]
>
> #####
> # User www's crontab
> # Note, I also tried removing the MAILTO to no avail
> #####
> MAILTO=root
> # m     h       dom     mon     dow     cmd
> *       *       *       *       *       echo "Hello"
>
>
[snip]

1.)  You are not using the full path to /bin/echo, which is why it is failing.

2.) This is a poor designed way to test cron's mail output.

A Better(tm) way would be something like:
MAILTO=root
*/5 * * * * /bin/ping -c1 localhost >/dev/null

which would mail to root on success or failure.

Regards,

-- 
Glen Barber


More information about the freebsd-questions mailing list