Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 28 May 2010 13:42:45 +0200
From:      Laszlo Nagy <gandalf@shopzeus.com>
To:        questions@freebsd.org
Subject:   cron not sending emails
Message-ID:  <4BFFAC35.2040503@shopzeus.com>

next in thread | raw e-mail | index | archive | help
Hi All!

After upgrading to 8.0 RELEASE, I'm not getting any emails from cron.

If I put this into root's crontab

* * * * * echo "TEST"

then I see this in the maillog:

May 14 10:53:00 server postfix/sendmail[2958]: fatal: user(1001): No 
recipient addresses found in message header


I'm using postfix. Sendmail config looks fine:

A /etc/mail/mailer.conf -ban ez van:

#
# Execute the Postfix sendmail program, named /usr/local/sbin/sendmail
#
sendmail    /usr/local/sbin/sendmail
send-mail    /usr/local/sbin/sendmail
mailq        /usr/local/sbin/sendmail
newaliases    /usr/local/sbin/sendmail

I tried to run "cron -x":

# cron -x bit,ext,load,misc,pars,proc,sch > cron.log
debug flags enabled: ext sch proc pars load misc bit
[92380] cron started
log_it: (tmp.27734 92380) ORPHAN (no passwd entry)
log_it: (root 92429) CMD (echo "Test")
^C

The cron.log file itself is very very long (there are many programs and 
user configs). I'll paste the relevant parts only:

   root:load_user()
load_env, read <MAILTO=gandalf>
load_env, <MAILTO> <gandalf> -> <MAILTO=gandalf>
load_env, read <SHELL=/bin/sh>
load_env, <SHELL> </bin/sh> -> <SHELL=/bin/sh>
load_env, read 
<PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin>
load_env, <PATH> 
</bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin> -> 
<PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin>
load_env, read <* * * * * echo "Test">
load_env, parse error, state = 7
load_entry()...about to eat comments
load_entry()...about to parse numerics
load_entry()...about to parse command
load_entry()...returning successfully
...load_user() done
[done]

At the end of the file:

[2400] checking account with PAM
[2401] grandchild process Vfork()'ed
[2402] grandchild process Vfork()'ed
[2403] grandchild process Vfork()'ed
[2404] grandchild process Vfork()'ed
[2405] grandchild process Vfork()'ed
[2395] child continues, closing pipes
[2395] child reading output from grandchild
[2406] grandchild process Vfork()'ed
[2396] child continues, closing pipes
[2396] child reading output from grandchild
[2397] child continues, closing pipes
[2397] child reading output from grandchild
[2398] child continues, closing pipes
[2398] child reading output from grandchild
[2399] child continues, closing pipes
[2399] child reading output from grandchild
[2400] child continues, closing pipes
[2400] child reading output from grandchild
[2395] closing pipe to mail
[2331] sigchld...pid #2395 died, stat=0
[2331] sigchld...no dead kids
[2331] TargetTime=1275040320, sec-to-wait=60
[2331] sleeping for 60 seconds
[2399] got EOF from grandchild
[2399] waiting for grandchild #2 to finish
[2399] grandchild #2404 finished, status=0000
[2399] waiting for grandchild #1 to finish
[2399] no more grandchildren--mail written?
[2399] child process done, exiting
[2331] sigchld...pid #2399 died, stat=0
[2331] sigchld...no dead kids
[2331] TargetTime=1275040320, sec-to-wait=60
[2331] sleeping for 60 seconds
[2398] got EOF from grandchild
[2398] waiting for grandchild #2 to finish
[2398] grandchild #2405 finished, status=0000
[2398] waiting for grandchild #1 to finish
[2398] no more grandchildren--mail written?
[2398] child process done, exiting
[2331] sigchld...pid #2398 died, stat=0
[2331] sigchld...no dead kids
[2331] TargetTime=1275040320, sec-to-wait=60
[2331] sleeping for 60 seconds
[2397] got EOF from grandchild
[2397] waiting for grandchild #2 to finish
[2397] grandchild #2403 finished, status=0000
[2397] waiting for grandchild #1 to finish
[2397] no more grandchildren--mail written?
[2397] child process done, exiting
[2331] sigchld...pid #2397 died, stat=0
[2331] sigchld...no dead kids
[2331] TargetTime=1275040320, sec-to-wait=59
[2331] sleeping for 59 seconds

So, what is wrong?

Thanks,

   Laszlo




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4BFFAC35.2040503>