Why logrotate using "size" threshold for some log files even though no "size" parameter used in the configuration file?
Issue
- Why logrotate using "size" threshold for some log files even though no "size" parameter used in the configuration file?
-
The logrotate config file has no "size" parameter.
$ cat /etc/logrotate.d/syslog /var/log/cron /var/log/maillog /var/log/messages /var/log/secure /var/log/spooler { missingok sharedscripts postrotate /usr/bin/systemctl kill -s HUP rsyslog.service >/dev/null 2>&1 || true endscript }
But the debug log shows that it is considered to use "size" threshold.
considering log /var/log/cron Now: 2021-03-10 17:45 Last rotated at 2021-02-25 03:17 log does not need rotating (log size is below the 'size' threshold) considering log /var/log/messages Now: 2021-03-10 17:45 Last rotated at 2021-03-09 03:17 log does not need rotating (log size is below the 'size' threshold)
Environment
- Red Hat Enterprise Linux
- logrotate
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.