Bug 1287539 - xattrs on directories are unavailable on distributed replicated volume after adding new bricks
Summary: xattrs on directories are unavailable on distributed replicated volume after ...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: distribute
Version: mainline
Hardware: x86_64
OS: Linux
urgent
urgent
Target Milestone: ---
Assignee: Susant Kumar Palai
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: 1285167 1296108
TreeView+ depends on / blocked
 
Reported: 2015-12-02 10:11 UTC by Susant Kumar Palai
Modified: 2016-06-16 13:47 UTC (History)
12 users (show)

Fixed In Version: glusterfs-3.8rc2
Doc Type: Bug Fix
Doc Text:
Clone Of: 1285167
: 1296108 (view as bug list)
Environment:
Last Closed: 2016-06-16 13:47:58 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Comment 1 Vijay Bellur 2015-12-02 10:11:52 UTC
REVIEW: http://review.gluster.org/12845 (cluster/dht: Handle failure in getxattr) posted (#1) for review on master by Susant Palai (spalai)

Comment 2 Susant Kumar Palai 2015-12-02 10:38:54 UTC
Description of problem:

Adding new bricks to a distributed replicated volume results in unavailability of xattrs on directories on distributed replicated volume where gluster is creating the dirs on the new bricks but not with the appropriate xattrs as xattrs on files are fine.

How reproducible:

1. Create test volume and start
gluster vol create test replica 2 server1:/brick01/bricksrv01/test server2:/brick01/bricksrv02/test ; gluster vol test start

2. Mount the volume via fuse
mkdir -p /mnt/gluster/test; mount -t glusterfs -o defaults,_netdev server1:test /mnt/gluster/test
 
3. Generate some dummy data
cd /mnt/gluster/test;mkdir dir{1..20};touch dir{1..20}/testfile

4. Set xattrs on files and directories
find . -exec setfattr -n user.swift.metadata -v dummyMetadataForTesting {} \;

5. Confirm xattrs are retrievable. xattrs should be retrievable for both files and directories find . -type f -exec getfattr -d -m. -e text {} \; find . -type d -exec getfattr -d -m. -e text {} \;

6. Add 2 new bricks to volume
gluster vol add-brick test replica 2 server3:/brick01/bricksrv03/test server4:/brick01/bricksrv04/test

7. Rebalance the volume.

8. Try and retrieve xattrs on files. This should succeed.
find . -type f -exec getfattr -d -m. -e text {} \;

9. Try and retrieve xattrs on dirs. All dirs should fail with "user.swift.metadata: No such attribute"
Find . -type d -exec getfattr -d -m. -e text {} \;

Actual results:

"user.swift.metadata: No such attribute" xattrs on directory after adding bricks.

Expected results:

Result with user.swift.metadata="dummyMetadataForTesting" xattrs as per file after adding bricks.

Comment 3 Vijay Bellur 2015-12-09 09:02:59 UTC
REVIEW: http://review.gluster.org/12845 (cluster/dht: Handle failure in getxattr) posted (#2) for review on master by Susant Palai (spalai)

Comment 4 Vijay Bellur 2015-12-09 13:17:46 UTC
REVIEW: http://review.gluster.org/12845 (cluster/dht: Handle failure in getxattr) posted (#3) for review on master by Susant Palai (spalai)

Comment 5 Vijay Bellur 2015-12-15 09:09:39 UTC
REVIEW: http://review.gluster.org/12845 (cluster/dht: Handle failure in getxattr) posted (#4) for review on master by Susant Palai (spalai)

Comment 6 Vijay Bellur 2015-12-17 07:09:57 UTC
COMMIT: http://review.gluster.org/12845 committed in master by Raghavendra G (rgowdapp) 
------
commit 692ccdbd4d11311a1967d62227666d2c473ea233
Author: Susant Palai <spalai>
Date:   Wed Dec 2 04:59:55 2015 -0500

    cluster/dht: Handle failure in getxattr
    
    Problem: Currently even if we have received xattrs from any one of
    the subvolume, we unwind with error in case the last subvol (which
    unwinds) received a negative response.
    
    To handle the case check if any of the subvolume has received
    a response and pass it down.
    
    Change-Id: Ia12a1f9671a6764f7550e6dc223324b1039fcc51
    BUG: 1287539
    Signed-off-by: Susant Palai <spalai>
    Reviewed-on: http://review.gluster.org/12845
    Tested-by: NetBSD Build System <jenkins.org>
    Tested-by: Gluster Build System <jenkins.com>
    Reviewed-by: Raghavendra G <rgowdapp>

Comment 7 Vijay Bellur 2015-12-21 06:48:47 UTC
REVIEW: http://review.gluster.org/12880 (cluster/dht: Heal user xattrs) posted (#5) for review on master by Susant Palai (spalai)

Comment 8 Vijay Bellur 2015-12-22 06:47:50 UTC
REVIEW: http://review.gluster.org/12880 (cluster/dht: Heal user xattrs) posted (#6) for review on master by Susant Palai (spalai)

Comment 9 Vijay Bellur 2015-12-28 06:50:50 UTC
REVIEW: http://review.gluster.org/12880 (cluster/dht: Heal user xattrs) posted (#7) for review on master by Susant Palai (spalai)

Comment 10 Mike McCune 2016-03-28 23:36:13 UTC
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions

Comment 11 Niels de Vos 2016-06-16 13:47:58 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


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