e-mail from cron
Bill Moran
wmoran at collaborativefusion.com
Wed Aug 23 18:06:12 UTC 2006
In response to David King <dking at ketralnis.com>:
> >> to this:
> >>
> >> # Perform daily/weekly/monthly maintenance.
> >> 1 3 * * * root periodic daily
> >> 2>&1 | sendmail service at jellico.com
> > [...]
> > However, you might find it easier to just add the following line to
> > the
> > top of the crontab:
> > MAILTO=service at jellico.com
> > Which will cause all mail generated by the jobs in that file to be
> > sent
> > to the provided address.
>
> Is that true? MAILTO should change the destination of the output of
> cron jobs, but periodic handles its own output
You're correct. That's my mistake and I apologize for the misinformation.
Simply put, periodic does not generate any output to either stdout or
stderr. It has its own system for determining who to mail to. See
/etc/defaults/periodic.conf or appropriate man pages for the details.
--
Bill Moran
Collaborative Fusion Inc.
More information about the freebsd-questions
mailing list