crontab作业的STDOUT和STDERR输出在哪里 [英] Where is the STDOUT and STDERR output of a crontab job

查看:65
本文介绍了crontab作业的STDOUT和STDERR输出在哪里的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有人知道CentOS中正常crontab作业输出的STDOUT和STDERR在哪里?

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

我检查了/var/log/cron 文件,但该文件仅记录了执行cron作业的时间和命令,没有找到STDOUT或STDERR内容.

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.

推荐答案

看看

/etc/rsyslog.d/

/etc/rsyslog.d/

您应该可以更改cron的日志级别.

there you should can change loglevel of cron .

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

删除#=最大日志记录

cron.err                /var/log/cron.log

仅错误日志

这篇关于crontab作业的STDOUT和STDERR输出在哪里的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆