Bug 1285958 - [GlusterD]: NFS service not running after layered installation of RHGS on RHEL7.x
[GlusterD]: NFS service not running after layered installation of RHGS on RHE...
Product: Red Hat Gluster Storage
Classification: Red Hat
Component: glusterd (Show other bugs)
x86_64 Linux
unspecified Severity high
: ---
: RHGS 3.1.2
Assigned To: Kaushal
: ZStream
Depends On: 1282915
Blocks: 1260783
  Show dependency treegraph
Reported: 2015-11-26 23:12 EST by Byreddy
Modified: 2016-03-10 02:02 EST (History)
9 users (show)

See Also:
Fixed In Version: glusterfs-3.7.5-8
Doc Type: Bug Fix
Doc Text:
Previously, rpcbind service did not start automatically after a layered installation on Red Hat Enterprise Linux 7. Due to this, GlusterFS NFS did not run after a reboot. With this fix, the GlusterD systemd unit was updated to explicitly require the rpcbind service. The GlusterFS NFS service now starts correctly on reboot.
Story Points: ---
Clone Of: 1282915
Last Closed: 2016-03-01 01:03:10 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Byreddy 2015-11-26 23:12:15 EST
+++ This bug was initially created as a clone of Bug #1282915 +++

Description of problem: Gluster does not reload gracefully upon server restart

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

How reproducible:

Steps to Reproduce:
1. Install GlusterFS as per docs on Centos7.
2. Create and start volume.
3. Restart server.

Actual results:
rpcbind service will not be active.

Expected results:
gluster will have registered with rpcbind

Additional info:

/usr/lib/systemd/system/glusterd.service has the following:
Description=GlusterFS, a clustered file-system server
After=network.target rpcbind.service

Changing to:
Description=GlusterFS, a clustered file-system server

Corrects the issue.

--- Additional comment from Red Hat Bugzilla Rules Engine on 2015-11-17 14:29:40 EST ---

This bug is automatically being proposed for the current z-stream release of Red Hat Gluster Storage 3 by setting the release flag 'rhgs‑3.1.z' to '?'. 

If this bug should be proposed for a different release, please manually change the proposed release flag.

--- Additional comment from Kaushal on 2015-11-18 00:55:39 EST ---

Thanks for reporting this. Turns out we've misunderstood the meaning of the `After` option.

According to the systemd.unit(5) man page, the `After` option only sets up ordering. If unit foo.service has the option `After=bar.service`, the option only ensures that if both foo and bar are started together, foo is started after bar. It doesn't ensure that starting only foo starts bar.

The `Requires` option only sets up the requirement, but doesn't set up ordering. If foo.service `Requires` bar.service, it is only guaranteed that starting foo will also start bar, but not necessarily in order.

The man page suggests that if a unit requires that another unit be started before itself, then both `After` and `Requires` must be used.

I've submitted a change for review that fixes this at http://review.gluster.org/12605

--- Additional comment from Vijay Bellur on 2015-11-18 05:21:10 EST ---

COMMIT: http://review.gluster.org/12605 committed in master by Atin Mukherjee (amukherj@redhat.com) 
commit 23440a73bc348bbc3bb43ec397f0639ee45865fc
Author: Kaushal M <kaushal@redhat.com>
Date:   Wed Nov 18 11:21:13 2015 +0530

    glusterd.service: Ensure rpcbind is started before glusterd
    Having the rpcbind.service under the `After` option only ensures that
    glusterd.service is started after rpcbind.service if both are
    enabled/started at the same time. It doesn't ensure that starting
    glusterd.service will start rpcbind.service.
    The systemd.unit(5) man page suggests to use both the `Requires` and
    `After` options to ensure that rpcbind is started before glusterd,
    whenever glusterd is started.
    BUG: 1282915
    Change-Id: Iee69965486be08711299aba235f7b00c3e2fe7e9
    Signed-off-by: Kaushal M <kaushal@redhat.com>
    Reviewed-on: http://review.gluster.org/12605
    Reviewed-by: Atin Mukherjee <amukherj@redhat.com>
    Reviewed-by: Anand Nekkunti <anekkunt@redhat.com>
    Tested-by: Gluster Build System <jenkins@build.gluster.com>
    Tested-by: NetBSD Build System <jenkins@build.gluster.org>
Comment 1 Byreddy 2015-11-26 23:21:42 EST
After layered installation of RHGS3.1.2 on RHEL7.1/2,
Created a sample volume ( Distributed ) and observed that **NFS SERVICE** not running in the volume status 

Steps to reproduce:
1. Install RHEL7.2 [OR] RHEL7.1 server
2. Do layered installation of RHGS //latest 3.1.2 OR 3.1.1
3. Start the glusterd 
4. Create a sample distributed volume 
5. Start the volume 
6. Check for NFS service in the volume status // it won't be running.

This issue is always reproducible with layered installation on RHE7.x
Comment 4 Kaushal 2015-11-27 04:07:03 EST
Backport posted for review at https://code.engineering.redhat.com/gerrit/62484
Comment 5 Byreddy 2015-12-01 05:58:50 EST
Done the Layered installation of  RHGS ON RHEL7.2  using the  version glusterfs-3.7.5-8 and done volume creation, everything worked fine ( NFS and rpcbind service  was running )

Moving to verified state
Comment 7 errata-xmlrpc 2016-03-01 01:03:10 EST
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.


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