[Cialug] Logrotate Issues with RHEL 6 on Manual entries

Kelly Slaugh kelly at visionary.com
Tue Dec 16 09:20:45 CST 2014


Hello everyone I was wondering if someone has an idea why my Logrotate is not working on a manual entry in the /etc/logrotate.d/httpd config file?

Weekly the logrotate is failing to cycle and compress my logs in the directory given.  This same logrotate command is running successfully on RHEL5 but not on RHEL6.  I checked to see if SELinux was causing a problem and that's not it.

When I run the command # logrotate -d file I get the error message "error: file access_log too large, probably not a config file.  removing last 0 log configs"  However the log is not too large, it's only 12M.

My Config file states this...  The logs that I need rotated in the first entry are owned by Apache and need to have apache restarted to create new ones.  Should I and the postrotate command just as Apache has for its logs?

//{dir}/[directory]/logs/*log {
    missingok
    notifempty
    sharedscripts
    postrotate
    endscript
}


/var/log/httpd/*log {
    missingok
    notifempty
    sharedscripts
    delaycompress
    postrotate
        /sbin/service httpd reload > /dev/null 2>/dev/null || true
    endscript
}

Any help is greatly appreciated.

Thank you

Kelly L. Slaugh // Systems Administrator
Visionary Services, Inc.

P1: 515.369.3545 ext. 116
visionary.com




More information about the Cialug mailing list