Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 490672 - sys-cluster/glusterfs-3.4.0-r1 - Logrotate config overwrites global settings from /etc/logrotate.conf
Summary: sys-cluster/glusterfs-3.4.0-r1 - Logrotate config overwrites global settings ...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Assignee: Gentoo Cluster Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-11-07 09:49 UTC by Christian Affolter
Modified: 2014-02-14 14:07 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Affolter 2013-11-07 09:49:45 UTC
The installed logrotate config snippet, located at /etc/logrotate.d/glusterfs, sets some logrotate options (such as weekly, rotate etc.) in the global scope, instead of the (gluster log) file scope.

This overwrites user defined settings from /etc/logrotate.conf For example, if one has configured logrotated to rotate the files on a daily basis, /etc/logrotate.d/glusterfs change this setting to a weekly basis. On a busy system this is can be fatal, as it might fill up the available space.

Reproducible: Always

Steps to Reproduce:
head -n 15 /etc/logrotate.d/glusterfs


Actual Results:  
# perform the log rotate every week
weekly
# keep the backup of 52 weeks
rotate 52
missingok

# compress the logs, but from the .2 onwards
compress
delaycompress
notifempty

# Rotate client logs
/var/log/glusterfs/*.log {
  sharedscripts
  postrotate


Expected Results:  
Please move all the gluster log file specific logrotate options to:

/var/log/glusterfs/*.log {
 [...]
}

and 

# Rotate server logs
/var/log/glusterfs/bricks/*.log {
  [...]
}

Apart from that, it is questionable if one really wants 52 weeks of back-logs.
Comment 1 Ultrabug gentoo-dev 2014-02-14 14:07:42 UTC
Indeed Christian, thanks for your patience.

I've shipped a logrotate script with the ebuilds now, it's fixed in tree.

+  14 Feb 2014; Ultrabug <ultrabug@gentoo.org> glusterfs-3.4.0-r1.ebuild,
+  glusterfs-3.4.1.ebuild, glusterfs-3.4.2.ebuild, +files/glusterfs.logrotate:
+  fix 3.4.x logrotate script #490672 thx to Christian Affolter
+