Where is the STDOUT and STDERR output of a crontab job

笑着哭i 提交于 2021-01-27 04:55:15

问题


Does any body know where is the STDOUT and STDERR of a normal crontab job output in CentOS?

I checked the /var/log/cron file, but it only record the time and command of a cron job executed, no STDOUT or STDERR content found there.


回答1:


Have a look on

/etc/rsyslog.d/

there you should can change loglevel of cron .

#cron.*                /var/log/cron.log

removing the # = maximum logging

cron.err                /var/log/cron.log

only error log



来源:https://stackoverflow.com/questions/28067714/where-is-the-stdout-and-stderr-output-of-a-crontab-job

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!