Bug 3961 - logrotate fails to execute create and postrotate in certain cases
Summary: logrotate fails to execute create and postrotate in certain cases
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: logrotate   
(Show other bugs)
Version: 6.0
Hardware: i386
OS: Linux
low
medium
Target Milestone: ---
Assignee: Erik Troan
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 1999-07-09 09:39 UTC by jens
Modified: 2008-05-01 15:37 UTC (History)
0 users

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


Attachments (Terms of Use)

Description jens 1999-07-09 09:39:31 UTC
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 18:45:08 UTC
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.