Bug 1090363

Summary: Add support in libgfapi to fetch volume info from glusterd.
Product: [Community] GlusterFS Reporter: Soumya Koduri <skoduri>
Component: libgfapiAssignee: Soumya Koduri <skoduri>
Status: CLOSED CURRENTRELEASE QA Contact: SATHEESARAN <sasundar>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: mainlineCC: bugs, gluster-bugs, kkeithle, sasundar
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-3.6.0beta1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1095775 1097603 (view as bug list) Environment:
Last Closed: 2014-11-11 08:30:32 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1095775, 1097603    

Description Soumya Koduri 2014-04-23 07:44:13 UTC
Description of problem:

Need APIs in libgfapi to fetch volume info (UUID atleast) from glusterd process and return it to the applications. Nfs-Ganesha need this support to read UUID of the volumes which will be used to uniquely identify them.

Comment 1 Anand Avati 2014-04-23 07:45:32 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#17) for review on master by soumya k (skoduri)

Comment 2 Anand Avati 2014-04-25 11:55:43 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#18) for review on master by soumya k (skoduri)

Comment 3 Soumya Koduri 2014-04-25 12:08:35 UTC
As part of this fix, we have defined a new RPC which will be invoked from libgfapi to glusterd process to fetch volume info. Incase of any failures while processing this RPC, glfs_init will return error eventually leading to application process to be killed.

And since this support is only needed for NFS-ganesha right now, if any issues are reported by other libgfapi users because of this new RPC added, we will make changes to not to bail out from glfs_init incase of failures reported in this RPC.

Also, we are bumping up the libgfapi version number in this patch. So before merging these changes to downstream, will send another patch to reset the version no.

Comment 4 Anand Avati 2014-04-28 07:55:44 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#19) for review on master by soumya k (skoduri)

Comment 5 Anand Avati 2014-04-28 07:59:45 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#20) for review on master by soumya k (skoduri)

Comment 6 Anand Avati 2014-04-30 10:38:33 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#21) for review on master by soumya k (skoduri)

Comment 7 Anand Avati 2014-04-30 11:35:24 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#22) for review on master by soumya k (skoduri)

Comment 8 Anand Avati 2014-05-02 06:27:19 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#23) for review on master by soumya k (skoduri)

Comment 9 Anand Avati 2014-05-02 09:17:29 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#24) for review on master by soumya k (skoduri)

Comment 10 Anand Avati 2014-05-07 08:37:38 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#25) for review on master by soumya k (skoduri)

Comment 11 Anand Avati 2014-05-07 08:40:57 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#26) for review on master by soumya k (skoduri)

Comment 12 Anand Avati 2014-05-07 09:49:00 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#27) for review on master by soumya k (skoduri)

Comment 13 Anand Avati 2014-05-09 05:15:41 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#28) for review on master by soumya k (skoduri)

Comment 14 Anand Avati 2014-05-09 05:24:14 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#29) for review on master by soumya k (skoduri)

Comment 15 Anand Avati 2014-05-09 05:33:18 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#30) for review on master by soumya k (skoduri)

Comment 16 Anand Avati 2014-05-09 09:59:23 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#31) for review on master by soumya k (skoduri)

Comment 17 Anand Avati 2014-05-09 10:03:40 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#32) for review on master by soumya k (skoduri)

Comment 18 Anand Avati 2014-05-09 10:45:12 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#33) for review on master by soumya k (skoduri)

Comment 19 Anand Avati 2014-05-10 05:53:08 UTC
REVIEW: http://review.gluster.org/7218 (libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.) posted (#34) for review on master by soumya k (skoduri)

Comment 20 Anand Avati 2014-05-11 09:47:48 UTC
COMMIT: http://review.gluster.org/7218 committed in master by Vijay Bellur (vbellur) 
------
commit 5adb10b9ac1c634334f29732e062b12d747ae8c5
Author: Soumya Koduri <skoduri>
Date:   Wed May 7 14:05:31 2014 +0530

    libgfapi:  Added support to fetch volume info from glusterd and store in glfs object.
    
    Defined new APIs in the libgfapi module, given a glfs object,
     * to send handshake RPC call to glusterd process to fetch UUID of the volume
     * store it in the glusterfs_context linked to the glfs object.
     * to parse UUID from its cannonical string format into 16-byte array
       before sending it to the libgfapi users.
    
    Defined a RPC call in glusterd which can be used to query volume related
    info by other processes using 'clnt_handshake_procs'.
    
    Note - Currently this RPC call to glusterd process is used only to fetch UUID.
    But it can be extended to get other volume related structures as well.
    
    In addition to the above, defined a new variable to keep track of such handshake
    RPCs still in progress to make sure all the corresponding RPC callbacks have been
    processed before libgfapi returns the glfs object initialized.
    
    Also bumping up the GFAPI current version number since there is a new API
    "glfs_get_volume_id" defined and exposed by libgfapi as part of these changes.
    
    Change-Id: I303f76d7177d32d25bdb301b1dbcf5cd73f42807
    BUG: 1090363
    Signed-off-by: Soumya Koduri <skoduri>
    Reviewed-on: http://review.gluster.org/7218
    Reviewed-by: Anand Avati <avati>
    Reviewed-by: Harshavardhana <harsha>
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Vijay Bellur <vbellur>

Comment 21 Soumya Koduri 2014-06-09 06:47:21 UTC
Verified the fix on the Glusterfs latest master branch available (Tag#v3.5qa2-579-g94fe2d3)

Comment 22 Niels de Vos 2014-09-22 12:38:34 UTC
A beta release for GlusterFS 3.6.0 has been released. Please verify if the release solves this bug report for you. In case the glusterfs-3.6.0beta1 release does not have a resolution for this issue, leave a comment in this bug and move the status to ASSIGNED. If this release fixes the problem for you, leave a note and change the status to VERIFIED.

Packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update (possibly an "updates-testing" repository) infrastructure for your distribution.

[1] http://supercolony.gluster.org/pipermail/gluster-users/2014-September/018836.html
[2] http://supercolony.gluster.org/pipermail/gluster-users/

Comment 23 Niels de Vos 2014-11-11 08:30:32 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.6.1, please reopen this bug report.

glusterfs-3.6.1 has been announced [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://supercolony.gluster.org/pipermail/gluster-users/2014-November/019410.html
[2] http://supercolony.gluster.org/mailman/listinfo/gluster-users