[mrtg] Re: E-mail Alarm for MRTG.

Kenneth Laulund Nielsen kenneth at privatpost.dk
Tue Aug 29 08:43:19 MEST 2000


Is it then possible to have mrtg put the output in an log file insted of

mailing it to an user? Because it is very annoying to mhave the mail box
filled if a machine is not up and running!!

Kenneth L. Nielsen

Justin Shore skriver:

>         While creating a mail alias or moving the cron stuff to
> another user would work, it basically sucks because you have to redo
> what you've already done, changing your habits, adding users,
> actually requires work, blah blah blah.  Want an easy solution?  When
> crond runs something and it generates a STDOUT or STDERR it sends
> mail to the owner of the crontab.  That's a given.  To change this
> behavior, add this line to your mrtg user's crontab:
> MAILTO="jack at talink.net"
> Put it right before your block of MRTG cron entries so it defines
> that environment variable before they run.  From that point in the
> crontab on all STDOUT and STDERR will be sent to the user you define.
> Likewise if you don't want any mail sent you could make it MAILTO="".
> If you want your MRTG user to actually receive certain pieces of
> mail, put them at the beginning of the crontab before your MAILTO tag.

> For that tidbit of cron joy and many others...
> man 5 crontab
>    Justin

Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi

More information about the mrtg mailing list