Bug 1285152

Summary: store afr pending xattrs as a volume option
Product: [Community] GlusterFS Reporter: Ravishankar N <ravishankar>
Component: replicateAssignee: Ravishankar N <ravishankar>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: mainlineCC: bugs
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-3.8.0 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1291985 (view as bug list) Environment:
Last Closed: 2016-06-16 12:31:57 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: 1291985    

Description Ravishankar N 2015-11-25 04:40:02 UTC
Description of problem:

    Problem:
    When AFR xlator initialises, it uses the name of the client xlators
    below it for storing the pending changelogs (xattrs). This can be
    problem when some other xlator is loaded in between AFR and the client.
    Though that is a trivial 'traverse-graph-till-the-client-and-use-the-name'
    fix in AFR's init(), there are other issues like when there's no client
    xlator at all when, say, AFR is moved to the server side.

    Fix:
    The client xlator names are currenly unique and stored as
    brickinfo->brick_ids. So persist these ids as comma separated values in
    AFR's volume_options and use them as xattr values during init().

Comment 1 Ravishankar N 2015-11-25 04:46:01 UTC
http://review.gluster.org/#/c/12738/

Comment 2 Vijay Bellur 2015-11-25 09:38:04 UTC
REVIEW: http://review.gluster.org/12738 (glusterd/afr: store afr pending xattrs as a volume option) posted (#2) for review on master by Ravishankar N (ravishankar)

Comment 3 Vijay Bellur 2015-11-27 12:10:19 UTC
REVIEW: http://review.gluster.org/12738 (glusterd/afr: store afr pending xattrs as a volume option) posted (#3) for review on master by Ravishankar N (ravishankar)

Comment 4 Vijay Bellur 2015-11-27 15:18:59 UTC
REVIEW: http://review.gluster.org/12738 (glusterd/afr: store afr pending xattrs as a volume option) posted (#4) for review on master by Ravishankar N (ravishankar)

Comment 5 Vijay Bellur 2015-12-07 12:26:12 UTC
REVIEW: http://review.gluster.org/12738 (glusterd/afr: store afr pending xattrs as a volume option) posted (#5) for review on master by Ravishankar N (ravishankar)

Comment 6 Vijay Bellur 2015-12-08 08:48:23 UTC
REVIEW: http://review.gluster.org/12738 (glusterd/afr: store afr pending xattrs as a volume option) posted (#6) for review on master by Ravishankar N (ravishankar)

Comment 7 Vijay Bellur 2015-12-08 21:47:06 UTC
REVIEW: http://review.gluster.org/12738 (glusterd/afr: store afr pending xattrs as a volume option) posted (#7) for review on master by Vijay Bellur (vbellur)

Comment 8 Vijay Bellur 2015-12-15 17:59:29 UTC
REVIEW: http://review.gluster.org/12738 (glusterd/afr: store afr pending xattrs as a volume option) posted (#8) for review on master by Ravishankar N (ravishankar)

Comment 9 Vijay Bellur 2015-12-16 06:17:18 UTC
COMMIT: http://review.gluster.org/12738 committed in master by Atin Mukherjee (amukherj) 
------
commit 6e635284a4411b816d4d860a28262c9e6dc4bd6a
Author: Ravishankar N <ravishankar>
Date:   Wed Nov 25 09:49:19 2015 +0530

    glusterd/afr: store afr pending xattrs as a volume option
    
    Problem:
    When AFR xlator initialises, it uses the name of the client xlators
    below it for storing the pending changelogs (xattrs). This can be
    problem when some other xlator is loaded in between AFR and the client.
    Though that is a trivial 'traverse-graph-till-the-client-and-use-the-name'
    fix in AFR's init(), there are other issues like when there's no client
    xlator at all when, say, AFR is moved to the server side.
    
    Fix:
    The client xlator names are currenly unique and stored as
    brickinfo->brick_ids. So persist these ids as comma separated values in
    AFR's volume_options and use them as xattr values during init().
    
    Change-Id: Ie761ffeb3373a4c4d85ad05c84a768c4188aa90d
    BUG: 1285152
    Signed-off-by: Ravishankar N <ravishankar>
    Reviewed-on: http://review.gluster.org/12738
    Tested-by: NetBSD Build System <jenkins.org>
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Atin Mukherjee <amukherj>

Comment 10 Ravishankar N 2016-06-03 14:48:20 UTC
Moving it back to POST since I'm sending a subsequent modification.

Comment 11 Vijay Bellur 2016-06-03 14:49:25 UTC
REVIEW: http://review.gluster.org/14642 (afr: afr-pending-xattr fallback check) posted (#1) for review on master by Ravishankar N (ravishankar)

Comment 12 Vijay Bellur 2016-06-03 15:12:53 UTC
REVIEW: http://review.gluster.org/14642 (afr: afr-pending-xattr fallback check) posted (#2) for review on master by Ravishankar N (ravishankar)

Comment 13 Vijay Bellur 2016-06-06 12:01:30 UTC
REVIEW: http://review.gluster.org/14642 (afr: afr-pending-xattr fallback check) posted (#3) for review on master by Ravishankar N (ravishankar)

Comment 14 Vijay Bellur 2016-06-08 03:59:20 UTC
REVIEW: http://review.gluster.org/14642 (afr: afr-pending-xattr fallback check) posted (#4) for review on master by Ravishankar N (ravishankar)

Comment 15 Vijay Bellur 2016-06-08 10:53:15 UTC
REVIEW: http://review.gluster.org/14642 (afr: afr-pending-xattr fallback check) posted (#5) for review on master by Ravishankar N (ravishankar)

Comment 16 Vijay Bellur 2016-06-09 08:20:49 UTC
COMMIT: http://review.gluster.org/14642 committed in master by Pranith Kumar Karampuri (pkarampu) 
------
commit 51e1028373b4a4082a771001b813d6f19aeacb37
Author: Ravishankar N <ravishankar>
Date:   Fri Jun 3 18:22:22 2016 +0530

    afr: afr-pending-xattr fallback check
    
    Commit 6e635284a4411b816d4d860a28262c9e6dc4bd6a introduced a comma
    separated list of values to be used as AFR's pending changelogs. If
    this xlator option is missing in the volfile, fall back to using client
    xlator names for constructing the pending changelog names.
    
    Also, since the aforementioned commit was reverted from 3.7 and 3.8
    branches, introduce GD_OP_VERSION_3_9_0 and change the op-version for this
    feature to GD_OP_VERSION_3_9_0.
    
    Change-Id: I3639b9ab475bd8d9929cc7527d9f4584dee1ad1b
    BUG: 1285152
    Signed-off-by: Ravishankar N <ravishankar>
    Reviewed-on: http://review.gluster.org/14642
    Smoke: Gluster Build System <jenkins.com>
    CentOS-regression: Gluster Build System <jenkins.com>
    Reviewed-by: Pranith Kumar Karampuri <pkarampu>
    NetBSD-regression: NetBSD Build System <jenkins.org>

Comment 17 Niels de Vos 2016-06-16 12:31:57 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.8.0, please open a new bug report.

glusterfs-3.8.0 has been announced on the Gluster mailinglists [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://blog.gluster.org/2016/06/glusterfs-3-8-released/
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user