This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 986948 - quota: limit crosses for symlink
quota: limit crosses for symlink
Product: Red Hat Gluster Storage
Classification: Red Hat
Component: glusterd (Show other bugs)
x86_64 Linux
high Severity high
: ---
: ---
Assigned To: krishnan parthasarathi
: ZStream
Depends On:
  Show dependency treegraph
Reported: 2013-07-22 09:29 EDT by Saurabh
Modified: 2016-01-19 01:15 EST (History)
9 users (show)

See Also:
Fixed In Version: glusterfs-
Doc Type: Bug Fix
Doc Text:
Previously, setting quota limits on symlinks was possible to directories but fail to enforce quota. Now, in this update, setting quota limits on symlinks is not possible.
Story Points: ---
Clone Of:
Last Closed: 2013-11-27 10:29:35 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Saurabh 2013-07-22 09:29:03 EDT
Description of problem:
created a dir 
create a symlink
set quota limit on symlink
and limit crosses

Version-Release number of selected component (if applicable):
[root@nfs1 ~]# rpm -qa | grep glusterfs

How reproducible:

Steps to Reproduce:
1. create a volume, start it
2. enable quota on the volume
3. set some limit on quota
4. mount the volume using nfs.
5. create a dir
[root@rhsauto030 nfs-test]# mkdir foo
6. create a link for dir
[root@rhsauto030 nfs-test]# ln -s foo bar

[root@rhsauto030 nfs-test]# ls -l 
total 480
lrwxrwxrwx. 1 root root     3 Jul 22 07:54 bar -> foo
drwxr-xr-x. 2 root root    36 Jul 22 07:53 foo

7. set limit on the symlink,
[root@nfs1 ~]# gluster volume quota quota-dist-rep limit-usage /bar 10MB
hard limit set on /bar

8. create a file of 100MB now after cding in bar,

Actual results:

[root@rhsauto030 bar]# dd if=/dev/zero of=f.1 bs=100MB count=1
1+0 records in
1+0 records out
100000000 bytes (100 MB) copied, 4.6002 s, 21.7 MB/s

Expected results:
symlink should accept the quota policies.

Additional info:
Comment 3 vpshastry 2013-09-04 04:58:44 EDT
Working for me in my setup with the new build v3.4.0qa8. Can you verify?
Comment 4 vpshastry 2013-09-04 05:08:30 EDT
Cause: The update wasn't happening if it was a symlink in the older implementation, which is not the current case.
Comment 5 vpshastry 2013-09-04 06:31:06 EDT
Cause in detail: In the quotad while updating the quota-limit directories, if the path is a symlink, we were not following the symlink to update the directory with the usage. This causes the quota limits to exceed.
Comment 6 Gowrishankar Rajaiyan 2013-10-03 05:44:19 EDT
Can we please have the patch URL ?
Comment 9 errata-xmlrpc 2013-11-27 10:29:35 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

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