Description of problem: In RHEL7 / systemd, the /etc/sysconfig/glusterd file is not being read. As a consequence, we can not override options. In particular, LOG_LEVEL would be handy. Version-Release number of selected component (if applicable): RHGS 3.1 on RHEL7 How reproducible: 100% Steps to Reproduce: 1. Install RHGS 3.1 on RHEL7 2. edit /etc/sysconfig/glusterd : LOG_LEVEL=TRACE 3. systemctl start glusterd.service Actual results: We are still in default logging level Expected results: debug level Additional info: systemd has a 'EnvironmentFile' entry that can be used to read /etc/sysconfig/glusterd.
We need to set environment variable in service file (/usr/lib/systemd/system/glusterd.service file) 1).Set environment variable EnvironmentFile=/etc/sysconfig/glusterd 2). Pass LOG_LEVEL to ExecStart ExecStart=/usr/sbin/glusterd -p /var/run/glusterd.pid $LOG_LEVEL
Upstream patch: http://review.gluster.org/#/c/12175/
Upstream patch merged.
Downstream patch https://code.engineering.redhat.com/gerrit/#/c/59493/
Downstream patch merged, so moving to modified
This Bug verified with the rhgs ver: 3.1.2 ( glusterfs-3.7.5 ). Found that Fix is working correctly and it's reading the /etc/sysconfig/glusterd file for log_level. Step done before moving to verified state: ========================================== 1. Have one node with 3.1.2 build (glusterfs-3.7.5) 2. Edited the /etc/sysconfig/glusterd file. [root@ ~]# cat /etc/sysconfig/glusterd ## Set custom log file and log level (bellow are defaults) LOG_FILE='/var/log/glusterfs/glusterd.log' LOG_LEVEL='TRACE' ## Set custom options for glusterd # GLUSTERD_OPTIONS='' [root@ ~]# 3. restarted the glusterd (systemctl restart glusterd.service) 4. Created one plane distributed volume 5. Checked the glusterd log, below is log details after above steps. [2015-11-02 04:36:02.329657] I [MSGID: 100030] [glusterfsd.c:2318:main] 0-/usr/sbin/glusterd: Started running /usr/sbin/glusterd version 3.7.5 (args: /usr/sbin/glusterd -p /var/run/glusterd.pid --log-level TRACE) [2015-11-02 04:36:02.329774] T [MSGID: 0] [glusterfsd.c:551:create_fuse_mount] 0-glusterfsd: mount point not found, not a client process [2015-11-02 04:36:02.331251] D [MSGID: 0] [glusterfsd.c:1984:glusterfs_pidfile_update] 0-glusterfsd: pidfile /var/run/glusterd.pid updated with pid 4751 [2015-11-02 04:36:02.331367] D [logging.c:1790:__gf_log_inject_timer_event] 0-logging-infra: Starting timer now. Timeout = 120, current buf size = 5 [2015-11-02 04:36:02.331836] D [MSGID: 0] [glusterfsd.c:638:get_volfp] 0-glusterfsd: loading volume file /etc/glusterfs/glusterd.vol [2015-11-02 04:36:02.332607] T [graph.y:186:new_volume] 0-parser: New node for 'management' [2015-11-02 04:36:02.332654] T [MSGID: 0] [xlator.c:189:xlator_dynload] 0-xlator: attempt to load file /usr/lib64/glusterfs/3.7.5/xlator/mgmt/glusterd.so [2015-11-02 04:36:02.339881] T [MSGID: 0] [xlator.c:240:xlator_dynload] 0-xlator: dlsym(reconfigure) on /usr/lib64/glusterfs/3.7.5/xlator/mgmt/glusterd.so: undefined symbol: reconfigure -- neglecting [2015-11-02 04:36:02.339942] T [graph.y:217:volume_type] 0-parser: Type:management:mgmt/glusterd Based one above details moving this bug to verified state.
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-0192.html