Re: How to stop a cron job sending email
- From: Erik Christiansen <dvalin@xxxxxxxxxxxxxxxx>
- Date: Fri, 31 Oct 2008 22:15:18 +1100
On Fri, Oct 31, 2008 at 10:58:22AM +0000, Chris Rees wrote:
2008/10/31 Johann Spies <jspies@xxxxxxxxx>:
# m h dom mon dow command
0-59/5 * * * * /usr/local/bin/krypos
$ cat /usr/local/bin/krypos
#!/bin/sh
killall fetchmail &> /dev/null
/usr/bin/fetchmail &> /dev/null
I have also tried
0-59/5 * * * * /usr/local/bin/krypos &> /dev/null
But I still get the email every 5 minutes.
That did not happen on my old computer.
How do I stop this?
The actual redirect should be 2>&1
Yes, or specify "#!/bin/bash" when using bashisms.
Alternatively, putting the line:
MAILTO=""
before any crontab actions has served me well to stop cron sending mail
in the first place, obviating the need to intercept it afterwards.
Erik
--
A computer is like an air conditioner, it stops working when you open Windows.
- Seen in Matthias Apitz's sig, on mutt-users.
--
ubuntu-users mailing list
ubuntu-users@xxxxxxxxxxxxxxxx
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users
- Follow-Ups:
- Re: How to stop a cron job sending email
- From: Johann Spies
- Re: How to stop a cron job sending email
- References:
- How to stop a cron job sending email
- From: Johann Spies
- Re: How to stop a cron job sending email
- From: Chris Rees
- How to stop a cron job sending email
- Prev by Date: Re: how to change terminal font size in Xubuntu?
- Next by Date: Re: Why is HAL being made the default when it's not ready?
- Previous by thread: Re: How to stop a cron job sending email
- Next by thread: Re: How to stop a cron job sending email
- Index(es):
Relevant Pages
|