Patrick Shanahan wrote:
* Till Wimmer <suse-e@tonarchiv.ch> [04-28-06 00:11]:
I want my apache log files to be rotated when they're bigger then 50M and ONLY when they're bigger.
But my /etc/logrotate.conf says: # rotate log files weekly weekly
I added a file /etc/logrotate.d/apache: /var/log/apache2/*.log { size=20M ... }
What's gonna happen? Are the files rotated even when they're smaller than 50M?
yes, you have size=20M
My config: size=+10M
Ah yes, of course - the 20M was a typo :) I was wondering because of the "weekly" in the global logrotate.conf. So what's more crucial: The weekly or the size=50M directive... and why? The man pages don't answer this. My /etc/logrotate.de/apache looks like this: /vhosts/substring/log/*.log /vhosts/tonarchiv/log/*.log /vhosts/safoso/log/*.log { size 50M rotate 9999 dateext compress delaycompress nocreate nocopy sharedscripts postrotate apachectl graceful endscript } Thanx - Till