Skip to main content

logrotate failing running postrotate script

Comments

3 comments

  • cPanelMichael
    Hello, Could you run the following commands and let us know the output?
    cat /etc/cron.daily/logrotate cat /etc/logrotate.conf
    Thank you.
    0
  • Fireminds Ltd.
    Here is the output: [root@server user]# cat /etc/cron.daily/logrotate #!/bin/sh export TMPDIR=/var/spool/logrotate/tmp /usr/sbin/logrotate /etc/logrotate.conf EXITVALUE=$? if [ $EXITVALUE != 0 ]; then /usr/bin/logger -t logrotate "ALERT exited abnormally with [$EXITVALUE]" fi exit 0 [root@server user]# cat /etc/logrotate.conf # see "man logrotate" for details # rotate log files weekly weekly # keep 4 weeks worth of backlogs rotate 4 # create new (empty) log files after rotating old ones create # use date as a suffix of the rotated file dateext # uncomment this if you want your log files compressed #compress # RPM packages drop log rotation information into this directory include /etc/logrotate.d # no packages own wtmp and btmp -- we'll rotate them here /var/log/wtmp { monthly create 0664 root utmp minsize 1M rotate 1 } /var/log/btmp { missingok monthly create 0600 root utmp rotate 1 } # system-specific logs may be also be configured here.
    0
  • cPanelMichael
    Hello, Do you have Exim disabled on this system in "WHM >> Service Manager"? If so, you can empty the /etc/logrotate.d/exim file to avoid those error messages with the following command:
    echo -n > /etc/logrotate.d/exim
    Then, if you decide to enable Exim again in the future, repopulate the file with the following commands:
    rm /etc/logrotate.d/exim /scripts/check_cpanel_rpms --fix
    Thank you.
    0

Please sign in to leave a comment.