Bug 1044405 - quota: make quota work with root-squash
Summary: quota: make quota work with root-squash
Keywords:
Status: CLOSED EOL
Alias: None
Product: GlusterFS
Classification: Community
Component: quota
Version: pre-release
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Susant Kumar Palai
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-12-18 09:22 UTC by Susant Kumar Palai
Modified: 2015-10-22 15:40 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-10-22 15:40:20 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Susant Kumar Palai 2013-12-18 09:22:41 UTC
Description of problem:
created a dir and changed the credentials of the dir to a non-root user.
then with root-squash on, tried to set limit for quota and it failed.

same is not seen when root-squash it put to off


How reproducible:
always

Steps to Reproduce:

1. create a directory
2. chown <some nonroot-user>:<some nonroot group> dir
3. root-squash on
4. quota enable 
5. set limit on dir created in step 1

Actual results:
Volume Name: dr1
Type: Distributed-Replicate
Volume ID: 72c8ab3e-7cb4-4313-9c61-bd4a85f60550
Status: Started
Number of Bricks: 6 x 2 = 12
Transport-type: tcp
Bricks:
Brick1: 10.70.37.213:/rhs/bricks/d1r1-1
Brick2: 10.70.37.145:/rhs/bricks/d1r2-1
Brick3: 10.70.37.68:/rhs/bricks/d2r1-1
Brick4: 10.70.37.76:/rhs/bricks/d2r2-1
Brick5: 10.70.37.213:/rhs/bricks/d3r1-1
Brick6: 10.70.37.145:/rhs/bricks/d3r2-1
Brick7: 10.70.37.68:/rhs/bricks/d4r1-1
Brick8: 10.70.37.76:/rhs/bricks/d4r2-1
Brick9: 10.70.37.213:/rhs/bricks/d5r1-1
Brick10: 10.70.37.145:/rhs/bricks/d5r2-1
Brick11: 10.70.37.68:/rhs/bricks/d6r1-1
Brick12: 10.70.37.76:/rhs/bricks/d6r2-1
Options Reconfigured:
server.root-squash: on
[root@nfs1 glusterfs-test]# gluster volume quota dr1 enable
volume quota : success
[root@nfs1 glusterfs-test]# gluster volume quota dr1 limit-usage /saurabh-dir 1GB
quota command failed : setxattr of 'trusted.glusterfs.quota.limit-set' failed on /tmp/dr1/saurabh-dir. Reason : Permission denied
[root@nfs1 glusterfs-test]# 



[root@rhsauto036 ~]# ls -l /mnt/nfs-test-dr1
total 1
drwxrwxrwx. 4 root    root    329 Sep  2 14:24 dir
-rw-r--r--. 1 root    root     12 Sep  2 00:16 nemo
-rwx------. 1 root    root     21 Sep  2 00:19 nepti
drwxr-xr-x. 2 saurabh saurabh  47 Sep  2 01:09 saurabh-dir

[root@nfs1 glusterfs-test]# 

Expected results:
rootsquash should not hamper setting limit on a directory

Additional info:

Comment 1 Kaleb KEITHLEY 2015-10-22 15:40:20 UTC
pre-release version is ambiguous and about to be removed as a choice.

If you believe this is still a bug, please change the status back to NEW and choose the appropriate, applicable version for it.


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