Joined: 23 Mar 2005
|Posted: Sun Apr 06, 2014 3:48 pm Post subject: Crontab email behavior
|I have two systems with identical /etc/crontab files like this:
0 0 * * * root /etc/cron.d/script.sh
script.sh is also identical on both systems. The script always has some output, but I get an email containing that output from one of the systems and not the other. Both systems send email successfully with this /etc/crontab:
0 0 * * * root /bin/echo "test"
An unsuccessful send looks like this in /var/mail/log/current:
Apr 06 07:50:07 [sSMTP] Creating SSL connection to host
Apr 06 07:50:08 [sSMTP] SSL connection using ECDHE-RSA-AES256-GCM-SHA384
A successful send looks like this:
Apr 06 08:15:01 [sSMTP] Creating SSL connection to host
Apr 06 08:15:01 [sSMTP] SSL connection using ECDHE-RSA-AES256-GCM-SHA384
Apr 06 08:15:03 [sSMTP] Sent mail for root@system (221 2.0.0 Bye) uid=0 username=root outbytes=310
How can I figure out what is going wrong?