Re: Crontab not sending mail with job output ?



On 2009-02-06, J.O. Aho <user@xxxxxxxxxxx> wrote:
The script produces some output to stdout when I run it manually.
When cron runs it (on my other machines) that output is wrapped in a mail
and send to my machines mailbox.

But that's not working here.

Look at the crontab how the line looks like, so it don't include
something like '&> /dev/null' as then you won't get any output and cron
won't mail anything.
Nope, nothing is beeing redirected to null or to a file.

Also it should have a 'MAILTO=root'.
Now that's something I can check. But what should have it where ?
I can't find an environment variable MAILTO, for one.

if you have a script in /etc/cron.* then check that the script don't
pipe it to /dev/null.
So far, I've only looked at a running a simple script in my ~/bin. And for
testing purposes, an simple echo of a text.

Also check that cron is really running, if not, you can prolly figure it
out...
It's running, the scripts get executed perfectly. And if I redirect it's
output to a file, that file get written to.


Weird, huh ?

--
Elevators smell different to midgets
.



Relevant Pages

  • Re: Crontab not sending mail with job output ?
    ... and send to my machines mailbox. ... it seems cron did it's job after all. ... Where do I even start looking at that mail delivery problem? ... Elevators smell different to midgets ...
    (alt.os.linux)
  • cron question
    ... At diferent time of the day the cron started to echo this message after ... some scripts was started: ...
    (RedHat)
  • Re: cron question
    ... > At diferent time of the day the cron started to echo this message after ... > some scripts was started: ...
    (RedHat)