Bug 1716848 - DHT: directory permissions are wiped out
Summary: DHT: directory permissions are wiped out
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: distribute
Version: 6
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Nithya Balachandran
QA Contact:
URL:
Whiteboard:
Depends On: 1716821 1716830
Blocks: 1737311
TreeView+ depends on / blocked
 
Reported: 2019-06-04 09:46 UTC by Nithya Balachandran
Modified: 2019-08-05 07:27 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1716830
Environment:
Last Closed: 2019-08-01 10:40:57 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Gluster.org Gerrit 22814 None Merged cluster/dht: Fix directory perms during selfheal 2019-08-01 10:40:56 UTC

Description Nithya Balachandran 2019-06-04 09:46:17 UTC
+++ This bug was initially created as a clone of Bug #1716830 +++

+++ This bug was initially created as a clone of Bug #1716821 +++

Description of problem:

A sequence of steps can wipe out the permissions set on a directory.

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

RHGS 3.5.0 

How reproducible:
Consistently

Steps to Reproduce:
[root@rhgs313-6 ~]# gluster volume create vol1 192.168.122.6:/bricks/brick1/vol1-1
volume create: vol1: success: please start the volume to access data
[root@rhgs313-6 ~]# gluster v start vol1
volume start: vol1: success
[root@rhgs313-6 ~]# mount -t glusterfs -s 192.168.122.6:/vol1 /mnt/fuse1
[root@rhgs313-6 fuse]# cd /mnt/fuse1
[root@rhgs313-6 fuse1]# mkdir dir1
[root@rhgs313-6 fuse1]# cd dir1/


[root@rhgs313-6 dir1]# getx /bricks/brick1/vol1-*/dir1
getfattr: Removing leading '/' from absolute path names
# file: bricks/brick1/vol1-1/dir1
security.selinux=0x756e636f6e66696e65645f753a6f626a6563745f723a756e6c6162656c65645f743a733000
trusted.gfid=0xbf9444c0f8614d81a5758ed801e9f7e0
trusted.glusterfs.dht=0x000000000000000000000000ffffffff
trusted.glusterfs.mdata=0x010000000000000000000000005cf629cf00000000302dadf6000000005cf629cf00000000302dadf6000000005cf629cf00000000302dadf6

[root@rhgs313-6 dir1]# gluster v add-brick vol1 192.168.122.6:/bricks/brick1/vol1-2 force
volume add-brick: success
[root@rhgs313-6 dir1]# ll
total 0




Check the directory permissions and xattrs on the bricks
[root@rhgs313-6 dir1]# ll /bricks/brick1/vol1-*
/bricks/brick1/vol1-1:
total 0
drwxr-xr-x. 2 root root 6 Jun  4 13:50 dir1

/bricks/brick1/vol1-2:
total 0
drwxr-xr-x. 2 root root 6 Jun  4 13:50 dir1

[root@rhgs313-6 dir1]# getx /bricks/brick1/vol1-*/dir1
getfattr: Removing leading '/' from absolute path names
# file: bricks/brick1/vol1-1/dir1
security.selinux=0x756e636f6e66696e65645f753a6f626a6563745f723a756e6c6162656c65645f743a733000
trusted.gfid=0xbf9444c0f8614d81a5758ed801e9f7e0
trusted.glusterfs.dht=0x000000000000000000000000ffffffff
trusted.glusterfs.mdata=0x010000000000000000000000005cf629cf00000000302dadf6000000005cf629cf00000000302dadf6000000005cf629cf00000000302dadf6

# file: bricks/brick1/vol1-2/dir1
security.selinux=0x756e636f6e66696e65645f753a6f626a6563745f723a756e6c6162656c65645f743a733000
trusted.gfid=0xbf9444c0f8614d81a5758ed801e9f7e0
trusted.glusterfs.dht=0x00000000000000000000000000000000
trusted.glusterfs.mdata=0x010000000000000000000000005cf629cf00000000302dadf6000000005cf629cf00000000302dadf6000000005cf629cf00000000302dadf6


From the mount point, cd one level up and then back again into dir1.

[root@rhgs313-6 dir1]# cd ..
[root@rhgs313-6 fuse1]# cd dir1
[root@rhgs313-6 dir1]# ll /bricks/brick1/vol1-*


Actual results:
[root@rhgs313-6 dir1]# ll /bricks/brick1/vol1-*
/bricks/brick1/vol1-1:
total 0
d---------. 2 root root 6 Jun  4 13:50 dir1

/bricks/brick1/vol1-2:
total 0
d---------. 2 root root 6 Jun  4 13:50 dir1


Expected results:
total 0
drwxr-xr-x. 2 root root 6 Jun  4 13:50 dir1

/bricks/brick1/vol1-2:
total 0
drwxr-xr-x. 2 root root 6 Jun  4 13:50 dir1

Additional info:

--- Additional comment from RHEL Product and Program Management on 2019-06-04 08:29:48 UTC ---

This bug is automatically being proposed for the next minor release of Red Hat Gluster Storage by setting the release flag 'rhgs‑3.5.0' to '?'. 

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

--- Additional comment from Worker Ant on 2019-06-04 09:28:44 UTC ---

REVIEW: https://review.gluster.org/22813 (cluster/dht: Fix directory perms during selfheal) posted (#1) for review on master by N Balachandran

Comment 1 Worker Ant 2019-06-04 09:51:38 UTC
REVIEW: https://review.gluster.org/22814 (cluster/dht: Fix directory perms during selfheal) posted (#1) for review on release-6 by N Balachandran

Comment 2 Worker Ant 2019-08-01 10:40:57 UTC
REVIEW: https://review.gluster.org/22814 (cluster/dht: Fix directory perms during selfheal) merged (#4) on release-6 by N Balachandran


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