Bug 1030432

Summary: quota: after quota remove command and still quota-deem-statfs on the df -h shows the "size" field shows lower value
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Saurabh <saujain>
Component: quotaAssignee: Susant Kumar Palai <spalai>
Status: CLOSED ERRATA QA Contact: Saurabh <saujain>
Severity: high Docs Contact:
Priority: high    
Version: 2.1CC: mzywusko, nsathyan, psriniva, rhs-bugs, spalai, ssamanta, storage-qa-internal, vagarwal, vbellur
Target Milestone: ---   
Target Release: RHGS 3.0.0   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: glusterfs-3.6.0.5-1.el6rhs Doc Type: Bug Fix
Doc Text:
Previously, even if the quota limit was not set, quota used to send the "quota-deem-statfs" key to the dictionary resulting in incorrect calculations. With this fix, the value of the "size" field for the mount point is cumulative of all the bricks and does not lead to incorrect calculation.
Story Points: ---
Clone Of:
: 1046894 (view as bug list) Environment:
Last Closed: 2014-09-22 19:29:44 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: 1046894    

Description Saurabh 2013-11-14 12:44:07 UTC
Description of problem:
The issue is about the df -h displays the "size" field for mount-point as not a cumulative of all bricks but the value displayed by size field is just showing the size of one of bricks.

while I did the quota remove , quota-deem-statfs was on.

quota remove is done in order to remove the earlier set limit on a certain path.

Version-Release number of selected component (if applicable):
glusterfs-3.4.0.44rhs-1

How reproducible:


Steps to Reproduce:
1. set some limit on root of the volume  and have quota-deem-statfs on for the volume
2. after mounting over nfs, create some data in it
3. take quota list
[root@nfs1 ~]# gluster volume quota dist-rep12 limit-usage / 300GB
volume quota : success

[root@nfs1 ~]# gluster volume quota dist-rep12 list
                  Path                   Hard-limit Soft-limit   Used  Available
--------------------------------------------------------------------------------
/                                        300.0GB       80%     160.8GB 139.2GB

[root@nfs1 ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
localhost:dist-rep12  300G  161G  140G  54% /var/run/gluster/dist-rep12

4. execute quota remove command

5. df -h


Actual results:
step 4
--------
[root@nfs1 ~]# 
[root@nfs1 ~]# gluster volume quota dist-rep12 remove /
volume quota : success

[root@nfs1 ~]# 

step 5
--------
[root@nfs1 ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/vg_nfs1-lv1
                      425G  167G  259G  40% /rhs/bricks
localhost:dist-rep12  425G  167G  258G  40% /var/run/gluster/dist-rep12


Expected results:
the value of size field for mountpoint should be cumulative of all bricks.

Additional info:


btw same case is found with just quota-deem-statfs on and not limit set on the volume.

[root@quota1 ~]# gluster volume set dist-rep quota-deem-statfs on
volume set: success
[root@quota1 ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/vg_quota1-lv_root
                       44G  2.7G   39G   7% /
tmpfs                 4.9G     0  4.9G   0% /dev/shm
/dev/vda1             485M   52M  408M  12% /boot
/dev/mapper/RHS_vgvdb-RHS_lv1
                      421G  234G  188G  56% /rhs/brick1
localhost:dist-rep    312G  236G   77G  76% /var/run/gluster/dist-rep

Comment 3 Vivek Agarwal 2014-05-22 11:12:22 UTC
Marking for denali as it got merged as a part of the rebase

Comment 4 Susant Kumar Palai 2014-05-22 11:18:28 UTC
Fixed in version : glusterfs-3.6.0.5-1.el6rhs

Comment 5 Saurabh 2014-06-19 10:58:01 UTC
based on the result moving this BZ to verified


[root@nfs1 ~]# df -h /var/run/gluster/dist-rep/dir
Filesystem          Size  Used Avail Use% Mounted on
localhost:dist-rep  300G  5.1G  295G   2% /var/run/gluster/dist-rep
[root@nfs1 ~]# 

[root@nfs1 ~]# gluster volume set dist-rep quota-deem-statfs off
volume set: success
[root@nfs1 ~]# 
[root@nfs1 ~]# df -h /var/run/gluster/dist-rep/dir
Filesystem          Size  Used Avail Use% Mounted on
localhost:dist-rep  2.5T   16G  2.5T   1% /var/run/gluster/dist-rep

Comment 6 Pavithra 2014-07-23 07:05:34 UTC
Hi Susant,

Please verify the edited doc text for technical accuracy and sign off.

Comment 7 Susant Kumar Palai 2014-09-15 11:27:18 UTC
Doc looks good to me.

Comment 9 errata-xmlrpc 2014-09-22 19:29:44 UTC
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.

http://rhn.redhat.com/errata/RHEA-2014-1278.html