Bug 3961 - logrotate fails to execute create and postrotate in certain cases
logrotate fails to execute create and postrotate in certain cases
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: logrotate (Show other bugs)
6.0
i386 Linux
low Severity medium
: ---
: ---
Assigned To: Erik Troan
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 1999-07-09 05:39 EDT by jens
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 1999-11-22 11:46:00 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description jens 1999-07-09 05:39:31 EDT
When using logrotate with the following config for e.g.
squid:

/var/log/squid/squid.logrotate {
    daily
    rotate 0
    ifempty
    nomissingok
    create
    postrotate
      /usr/sbin/squid -k rotate
    endscript
}

logrotate does not do anything but removing
/var/log/squid/squid.logrotate - older log files
will not be removed, but even worse, no new log
file is created and the postrotate script is not
executed.
A simple workaround is to set the number of rotations
to "1". Then, logrotate does its job as expected.

BTW, logrotate does not react correctly on the --usage
argument. Refering to the man page, a usage message, a
version indicator and a copyright message will be displayed.
However, I can only see a usage message.

The version of the logrotate RPM is: logrotate-3.2-1
Comment 1 Preston Brown 2001-06-21 14:45:08 EDT
Both of these things have been addressed in logrotate 3.5.6 and later (Rawhide).

Better late than never.


Note You need to log in before you can comment on or make changes to this bug.