Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1224639 - 'glusterd.socket' file created by rpm scriptlet is not cleaned-up properly post installation
'glusterd.socket' file created by rpm scriptlet is not cleaned-up properly po...
Status: CLOSED ERRATA
Product: Red Hat Gluster Storage
Classification: Red Hat
Component: glusterd (Show other bugs)
3.1
Unspecified Unspecified
high Severity high
: ---
: RHGS 3.1.0
Assigned To: Anand Nekkunti
Prasanth
:
Depends On:
Blocks: 1202842 1210404 1214253 1214258 1223636 1228109
  Show dependency treegraph
 
Reported: 2015-05-25 04:38 EDT by Prasanth
Modified: 2016-01-03 23:50 EST (History)
11 users (show)

See Also:
Fixed In Version: glusterfs-3.7.1-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-07-29 00:52:51 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:1495 normal SHIPPED_LIVE Important: Red Hat Gluster Storage 3.1 update 2015-07-29 04:26:26 EDT

  None (edit)
Description Prasanth 2015-05-25 04:38:38 EDT
Description of problem:

'glusterd.socket' file created by rpm scriptlet is not cleaned-up properly post installation

Version-Release number of selected component (if applicable):
glusterfs-fuse-3.7.0-2.el6rhs.x86_64
glusterfs-libs-3.7.0-2.el6rhs.x86_64
glusterfs-client-xlators-3.7.0-2.el6rhs.x86_64
glusterfs-api-3.7.0-2.el6rhs.x86_64
glusterfs-3.7.0-2.el6rhs.x86_64
glusterfs-cli-3.7.0-2.el6rhs.x86_64
glusterfs-server-3.7.0-2.el6rhs.x86_64


How reproducible: Always


Steps to Reproduce:
1. Install the RHGS 3.1 build 2
  # yum install glusterfs-server

Actual results:
AFAIK, the 'glusterd.socket' file is first created by rpm scriptlet as part of a start and stop operation done in the post upgrade script to re-generate the configuration files. During the process it gets a wrong label of "var_run_t" as we don't have filename transition rules in RHEL-6. However, as this file is not cleaned after the installation, the write access and unlink access required on the sock_file '/var/run/glusterd.socket' while manually starting 'glusterd' for the first time is prevented by SELinux. This is identified as the reason for the 2 SELinux bugs [1] and [2].

[1] https://bugzilla.redhat.com/show_bug.cgi?id=1214253

[2] https://bugzilla.redhat.com/show_bug.cgi?id=1214258

So doing a proper clean as part of post upgrade section of rpm installation is required to avoid issues like this.


Expected results: Any temporary files created as part of the rpm installation should be removed post installation. As part of that, 'glusterd.socket; should also get removed.


Additional info:

#####
[root@dhcp42-246 run]# /etc/init.d/glusterd status
glusterd is stopped

[root@dhcp42-246 run]# ls -lZ glusterd.socket 
srwxr-xr-x. root root unconfined_u:object_r:var_run_t:s0 glusterd.socket

[root@dhcp42-246 run]# /etc/init.d/glusterd start
Starting glusterd:                                         [  OK  ]

[root@dhcp42-246 run]# ls -lZ glusterd.socket 
srwxr-xr-x. root root unconfined_u:object_r:glusterd_var_run_t:s0 glusterd.socket

[root@dhcp42-246 run]# /etc/init.d/glusterd status
glusterd (pid  5278) is running...
#####
Comment 2 Prasanth 2015-06-22 03:42:45 EDT
Verified as fixed in glusterfs-3.7.1-4.el6rhs.x86_64

#####
[root@dhcp43-61 run]# /etc/init.d/glusterd status
glusterd is stopped

[root@dhcp43-61 run]# pwd
/var/run

[root@dhcp43-61 run]# ls -lZ glusterd.socket
ls: cannot access glusterd.socket: No such file or directory

[root@dhcp43-61 run]# /etc/init.d/glusterd start
Starting glusterd:                                         [  OK  ]

[root@dhcp43-61 run]#  ls -lZ glusterd.socket 
srwxr-xr-x. root root unconfined_u:object_r:glusterd_var_run_t:s0 glusterd.socket

[root@dhcp43-61 run]# /etc/init.d/glusterd status
glusterd (pid  2284) is running...
#####
Comment 5 errata-xmlrpc 2015-07-29 00:52:51 EDT
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/RHSA-2015-1495.html

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