Bug 69187 - logrotate cron script is misplaced
logrotate cron script is misplaced
Status: CLOSED WONTFIX
Product: Red Hat Linux
Classification: Retired
Component: logrotate (Show other bugs)
7.3
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Elliot Lee
Aaron Brown
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2002-07-18 14:40 EDT by Florin Andrei
Modified: 2007-04-18 12:44 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2002-07-18 14:40:05 EDT
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 Florin Andrei 2002-07-18 14:40:01 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 Galeon/1.2.5 (X11; Linux i686; U;) Gecko/20020606

Description of problem:
In the package provided by Red Hat, logrotate has its cron script in cron.daily:

[root@vrazalla florin]# rpm -ql logrotate
/etc/cron.daily/logrotate
/etc/logrotate.conf
/etc/logrotate.d
/usr/sbin/logrotate
/usr/share/doc/logrotate-3.6.4
/usr/share/doc/logrotate-3.6.4/CHANGES
/usr/share/man/man8/logrotate.8.gz
/var/lib/logrotate.status
[root@vrazalla florin]#

This is wrong, as it effectively prevents the "size" directive (see man
logrotate) to work efficiently.
"size" is designed to control rapid-growing logs and prevent them from eating up
entire partitions. But if logrotate is run only once a day, "size" cannot do its
job.
In fact, "size" was created to perform a finer control where "daily" is not good
enough. But the current layout of the package is opposed to that.

It is much better to put logrotate's cron script in cron.hourly, hence allowing
"size" to perform a tighter control.
And logrotate, if it doesn't to anything (just wakes up, checks whether it needs
to rotate some files, then goes to sleep again) is "cheap" to run (as in CPU and
disk I/O resources).

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.install logrotate
2.
3.
	

Actual Results:  the cron script is placed in cron.daily

Expected Results:  the cron script should be placed in cron.hourly

Additional info:
Comment 1 Elliot Lee 2002-08-08 12:00:18 EDT
If you have logfiles that are growing rapidly enough that you need hourly log rotation, you'll 
have to make the change yourself. Unfortunately, many more users will be upset if 
logrotate starts running every hour and taking CPU time from their stuff.

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