By default, crontab on, for example, Debian, will mail any output of a job in your crontab to that user. How would one go about disabling this functionality?
Tell me more
×
Server Fault is a question and answer site for
professional system and network administrators. It's 100% free, no registration required.
|
There are two main ways of doing this, as I discovered. Either you set the MAILTO-variable to nothing at the start of the file:
or you redirect each cronjobs output to /dev/null:
The second having the advantage that output on stderr should still be mailed to you. |
|||||||||||
|
|
To prevent output of both stdout and stderr use the following syntax:
|
|||
|
|