Skip to content

Instantly share code, notes, and snippets.

@robinbowes
Created October 6, 2014 15:24
Show Gist options
  • Save robinbowes/5ee24155a108c414e267 to your computer and use it in GitHub Desktop.
Save robinbowes/5ee24155a108c414e267 to your computer and use it in GitHub Desktop.
logrotate exits non-zero
[root@ip-10-33-141-171 logrotate.d]# logrotate -df /etc/logrotate.conf
reading config file /etc/logrotate.conf
including /etc/logrotate.d
reading config file dracut
reading config info for /var/log/dracut.log
reading config file puppet
reading config info for /var/log/puppet/*log
reading config file syslog
reading config info for /var/log/cron
/var/log/maillog
/var/log/messages
/var/log/secure
/var/log/spooler
reading config file yum
reading config info for /var/log/yum.log
reading config info for /var/log/wtmp
reading config info for /var/log/btmp
Handling 6 logs
rotating pattern: /var/log/dracut.log forced from command line (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/dracut.log
log does not need rotating
rotating pattern: /var/log/puppet/*log forced from command line (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/puppet/*log
log /var/log/puppet/*log does not exist -- skipping
not running postrotate script, since no logs were rotated
rotating pattern: /var/log/cron
/var/log/maillog
/var/log/messages
/var/log/secure
/var/log/spooler
forced from command line (4 rotations)
empty log files are rotated, old logs are removed
considering log /var/log/cron
log needs rotating
considering log /var/log/maillog
log needs rotating
considering log /var/log/messages
log needs rotating
considering log /var/log/secure
log needs rotating
considering log /var/log/spooler
log needs rotating
rotating log /var/log/cron, log->rotateCount is 4
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/cron-20141006 already exists, skipping rotation
rotating log /var/log/maillog, log->rotateCount is 4
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/maillog-20141006 already exists, skipping rotation
rotating log /var/log/messages, log->rotateCount is 4
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/messages-20141006 already exists, skipping rotation
rotating log /var/log/secure, log->rotateCount is 4
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/secure-20141006 already exists, skipping rotation
rotating log /var/log/spooler, log->rotateCount is 4
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/spooler-20141006 already exists, skipping rotation
rotating pattern: /var/log/yum.log forced from command line (4 rotations)
empty log files are not rotated, old logs are removed
considering log /var/log/yum.log
log needs rotating
rotating log /var/log/yum.log, log->rotateCount is 4
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/yum.log-20141006 already exists, skipping rotation
rotating pattern: /var/log/wtmp forced from command line (1 rotations)
empty log files are rotated, only log files >= 1048576 bytes are rotated, old logs are removed
considering log /var/log/wtmp
log needs rotating
rotating log /var/log/wtmp, log->rotateCount is 1
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/wtmp-20141006 already exists, skipping rotation
rotating pattern: /var/log/btmp forced from command line (1 rotations)
empty log files are rotated, old logs are removed
considering log /var/log/btmp
log needs rotating
rotating log /var/log/btmp, log->rotateCount is 1
dateext suffix '-20141006'
glob pattern '-[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
destination /var/log/btmp-20141006 already exists, skipping rotation
[root@ip-10-33-141-171 logrotate.d]# echo $?
1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment