Bug 1171865 - glusterfs logrotate config file clobbers defaults [rhel-6]
Summary: glusterfs logrotate config file clobbers defaults [rhel-6]
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: glusterfs
Version: 6.6
Hardware: All
OS: Linux
high
high
Target Milestone: rc
: ---
Assignee: sankarshan
QA Contact: SATHEESARAN
Petr Bokoc
URL:
Whiteboard:
: 1181315 1266210 (view as bug list)
Depends On:
Blocks: 1172231 1181315 1266214 1281259 1305492 1305493
TreeView+ depends on / blocked
 
Reported: 2014-12-08 19:46 UTC by Kevin Stange
Modified: 2019-10-10 09:31 UTC (History)
22 users (show)

Fixed In Version: glusterfs-3.7.5-19
Doc Type: Bug Fix
Doc Text:
Installing _glusterfs_ no longer affects default *logrotate* settings When installing the _glusterfs_ packages on Red Hat Enterprise Linux 6, the `glusterfs-logrotate` and `glusterfs-georep-logrotate` files were previously installed with several global *logrotate* options. Consequently, the global options affected the default settings in the `/etc/logrotate.conf` file. The glusterfs RPMs have been rebuilt to prevent the default settings from being overridden. As a result, global settings in `/etc/logrotate.conf` continue to function as configured without being overridden by settings from *glusterfs* `logrotate` files.
Clone Of:
: 1172542 1305492 1305493 (view as bug list)
Environment:
Last Closed: 2016-05-10 19:38:24 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Bugzilla 1292406 None None None Never
Red Hat Knowledge Base (Solution) 1353853 None None None Never
Red Hat Product Errata RHBA-2016:0747 normal SHIPPED_LIVE glusterfs bug fix and enhancement update 2016-05-10 22:31:28 UTC

Internal Links: 1292406

Description Kevin Stange 2014-12-08 19:46:53 UTC
Description of problem:

The glusterfs-logrotate (and glusterfs-georep-logrotate) file from the RPM contains several global logrotate options, such as "weekly", "rotate 52" and "compress" which are clobbering the default logrotate settings from /etc/logrotate.conf

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

3.6.0.29-2.el6

How reproducible:

100%

Actual results:

logrotate is keeping 52 weeks of compressed logs for all files not explicitly overriding the defaults.

Expected results:

logrotate should be honoring weekly, rotate 4 and no compress as per /etc/logrotate.conf shipped by default.

Comment 2 Kevin Stange 2014-12-10 01:04:53 UTC
Upon review, this was fixed upstream here:

https://forge.gluster.org/glusterfs-core/glusterfs/commit/a5d73daabf6df95bc73b186d92f3e2d1239a6f8a

Comment 4 Harshavardhana 2015-01-13 03:42:11 UTC
*** Bug 1181315 has been marked as a duplicate of this bug. ***

Comment 7 Terry Bowling 2015-02-26 21:35:01 UTC
Added gss tracker bz's.

because qemu-kvm depends on glusterfs-api, this results in any rhel 6.6/7.1 kvm hypervisor inheriting this logrotate config bug.

The following bz's resulted

  - bz1195947 - Reduce the contents of dependencies from glusterfs-api

  - bz1194503 - Dependency problem due to glusterfs-api depending on glusterfs instead of only glusterfs-libs [rhel-6]

  - bz1194508 - Dependency problem due to glusterfs-api depending on glusterfs instead of only glusterfs-libs [rhel-7]

Comment 12 Terry Bowling 2015-05-22 14:03:52 UTC
The short term fix for this is to correct the rsyslog configuration error.  I believe that was being addressed on bz1099539 for RHS.

Is this short term fix being addressed for RHEL 6.7?  I thought it was on this BZ but do not see any updates reflecting that.  It should be a very simple fix to release quickly.

Comment 16 Ryan Sawhill 2015-09-24 20:13:51 UTC
*** Bug 1266210 has been marked as a duplicate of this bug. ***

Comment 30 SATHEESARAN 2016-04-29 06:31:34 UTC
Tested with glusterfs-3.7.5-19.el6rhs and here are the observations

1. When qemu-kvm is installed, it pulls in glusterfs-api, glusterfs, glusterfs-libs and glusterfs-client-xlators

[root@ ~]# rpm -qR qemu-kvm | grep gluster
glusterfs-api  

[root@ ~]# rpm -qR glusterfs-api | grep gluster
glusterfs = 3.7.5-19.el6
glusterfs-client-xlators = 3.7.5-19.el6
libglusterfs.so.0()(64bit)  

[root@ ~]# rpm -qR glusterfs | grep gluster
glusterfs-libs = 3.7.5-19.el6
libglusterfs.so.0()(64bit)  

[root@ ~]# rpm -qR glusterfs-libs | grep gluster
libglusterfs.so.0()(64bit)  

[root@ ~]# rpm -qR glusterfs-client-xlators | grep gluster
libglusterfs.so.0()(64bit)  

2. No glusterfs binaries are installed as part of the above rpms and its dependencies installation
[root@ ~]# which glusterfs
/usr/bin/which: no glusterfs in (/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin)

[root@ ~]# which glusterfs
/usr/bin/which: no glusterfs in (/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin)

[root@ ~]# which glusterfsd
/usr/bin/which: no glusterfsd in (/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin)

[root@ ~]# which gluster
/usr/bin/which: no gluster in (/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin)

[root@ ~]# ls /usr/sbin/glusterfs
ls: cannot access /usr/sbin/glusterfs: No such file or directory

[root@ ~]# ls /usr/sbin/glusterfs*
ls: cannot access /usr/sbin/glusterfs*: No such file or directory

[root@ ~]# ls /usr/sbin/gluster*
ls: cannot access /usr/sbin/gluster*: No such file or directory

3. When installing glusterfs-fuse, it adds the logrotate conf file, which only logrotates glusterfs log files and glusterfs binaries. But glusterfs-fuse not made pulled in as a dependency by any other packages.

4. logrotate conf file has the content
# Rotate client logs
/var/log/glusterfs/*.log {
  sharedscripts
  weekly
  rotate 52
  missingok
  compress
  delaycompress
  notifempty
  postrotate
  /usr/bin/killall -HUP glusterfs > /dev/null 2>&1 || true
  /usr/bin/killall -HUP glusterd > /dev/null 2>&1 || true
  endscript
}

# Rotate server logs
/var/log/glusterfs/bricks/*.log {
  sharedscripts
  weekly
  rotate 52
  missingok
  compress
  delaycompress
  notifempty
  postrotate
  /usr/bin/killall -HUP glusterfsd > /dev/null 2>&1 || true
  endscript
}


Based on the above observations, verifying this bug

Comment 33 errata-xmlrpc 2016-05-10 19:38:24 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-0747.html


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