I have several cron jobs that run (in /etc/cron.daily, /etc/cron.hourly, /etc/cron.weekly, etc.) and email root@localhost with the results. I'd like to stop those emails if the jobs are succeeding, and only email on error (which I understand can be done by redirecting stdout to /dev/null). I understand how to do that for individual cron jobs, but the scripts in those special directories are run using run-parts. What is the best way to suppress success emails for those scripts?
Tell me more
×
Super User is a question and answer site for
computer enthusiasts and power users. It's 100% free, no registration required.
|
|
|||
|
|
|
You should send successful email notifications to But you want to see unsuccessful email notifications. This means you need to first direct try changing the redirection part of your cronjobs to
See this link |
|||||||||||||
|