From 714e45f0bb8ccf3674d4a821d0517d70a219f81a Mon Sep 17 00:00:00 2001 From: Joe LeVeque Date: Tue, 23 May 2017 10:29:54 -0700 Subject: [PATCH] Cron jobs log to /var/log/cron.log once again (#620) - Now that logrotate is a cron job that runs every minute, it was polluting syslog - Also shrink max size of less-important logs to 50MB and rotate them daily by default --- files/image_config/logrotate.d/rsyslog | 4 ++-- files/image_config/rsyslog/rsyslog.d/99-default.conf | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/files/image_config/logrotate.d/rsyslog b/files/image_config/logrotate.d/rsyslog index 0d03e906c9..d24bc32abe 100644 --- a/files/image_config/logrotate.d/rsyslog +++ b/files/image_config/logrotate.d/rsyslog @@ -31,8 +31,8 @@ /var/log/messages { rotate 4 - weekly - maxsize 100M + daily + maxsize 50M missingok notifempty compress diff --git a/files/image_config/rsyslog/rsyslog.d/99-default.conf b/files/image_config/rsyslog/rsyslog.d/99-default.conf index 9b129199b3..cfb1e1d3b8 100644 --- a/files/image_config/rsyslog/rsyslog.d/99-default.conf +++ b/files/image_config/rsyslog/rsyslog.d/99-default.conf @@ -3,9 +3,9 @@ # auth,authpriv.* /var/log/auth.log *.*;auth,authpriv.none -/var/log/syslog -# Do not redirect cron, daemon, kernel or lpr logs to +cron.* /var/log/cron.log +# Do not redirect daemon, kernel or lpr logs to # their own files. Let them log to /var/log/syslog -#cron.* /var/log/cron.log #daemon.* -/var/log/daemon.log #kern.* -/var/log/kern.log #kern.* -/var/persist/log/kern.log