Re: cron jobs + (some?) output
From: Ben Russo (ben_at_muppethouse.com)
To: email@example.com Date: Tue, 07 Dec 2004 17:12:31 -0500
Hugo Vanwoerkom wrote:
> I run mplayer from a script in the early morning as a cron job.
> My problem (small one) was that since there is no shell, where is the
> Gues what: it gets sent to root!
Yes, output from cron processes is sent via e-mail to the owner of the
process using local mail delivery agent. This is the standard way it
works. SURPRISE! (he he, just kidding, but this has been hapenning for
at least 15 years.)
If you were running the process in the root crontab, then the output of
the commands will be sent to the root user via local "mail" command.
If you want to stop this, you can redirect the output of the mplayer to
a file every day.... for example, in your crontab have something like
this: (Remember to remove the newlines, this is wrapped at 80 chars)
3 4 * * * rm -f /var/log/mplayer.log; mv /var/log/mplayer.log
/var/log/mplayer.log.yesterday; mplayer -command -options blah blah >
This command will create a new log every day, and keep yesterdays log
too, but will lose all older logs.
-- To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org with a subject of "unsubscribe". Trouble? Contact firstname.lastname@example.org