$ vi /etc/rsyslog.conf
找到此行:#$ModLoad imklog # reads kernel messages (the same are read from journald)
修改为:$ModLoad imklog # reads kernel messages (the same are read from journald)
找到此行:$OmitLocalLogging on
修改为:#$OmitLocalLogging on
找到此行:$IMJournalStateFile imjournal.state
修改为:#$IMJournalStateFile imjournal.state
重启日志服务:systemctl restart rsyslog
tail -f /var/log/cron 发现有输入信息了
转载于:https://www.cnblogs.com/jcksb/p/10972517.html