[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: crontab $MAILTO question



on Tue, Dec 11, 2001 at 09:33:59AM +1100, KenrickC@aap.com.au (KenrickC@aap.com.au) wrote:
> 
> >> Hi
> >>
> >> I make backups using a cron job and I set MAILTO=""
> >> Can I configure cron to mail me
> >> a) *only* when there were errors
> >> b) email only STDERR (not STDOUT)
> 
> Why not just remove the MAILTO line, and redirect
> standard output from the backup to /dev/null.  Presuming
> the application only writes standard error when there
> is an error, this should work, no?

Yes.  This is the proper approach.

Unsetting MAILTO IMVAO is a Bad Thing®.

-- 
Karsten M. Self <kmself@ix.netcom.com>       http://kmself.home.netcom.com/
 What part of "Gestalt" don't you understand?             Home of the brave
  http://gestalt-system.sourceforge.net/                   Land of the free
   Free Dmitry! Boycott Adobe! Repeal the DMCA! http://www.freesklyarov.org
Geek for Hire                     http://kmself.home.netcom.com/resume.html

Attachment: pgpNJz081iFK2.pgp
Description: PGP signature


Reply to: