Bug 1581231

Summary: quota crawler not working unless lookup is done from mount
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Vinayak Papnoi <vpapnoi>
Component: quotaAssignee: Sanoj Unnikrishnan <sunnikri>
Status: CLOSED ERRATA QA Contact: Vinayak Papnoi <vpapnoi>
Severity: medium Docs Contact:
Priority: unspecified    
Version: rhgs-3.4CC: rhs-bugs, sankarshan, sheggodu, srmukher, storage-qa-internal, sunnikri, vdas
Target Milestone: ---   
Target Release: RHGS 3.4.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-3.12.2-14 Doc Type: Bug Fix
Doc Text:
Previously, while quota was enabled on a volume, the quota used values were not updated to the list command until a lookup was done from the client mount point. Due to this, there was inaccuracy while reporting the file size even after performing the crawl operation. With this fix, it is ensured that the crawl operation looks up all files and reports the accurate quota used.
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-09-04 06:48:11 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: 1533000    
Bug Blocks: 1503137    

Description Vinayak Papnoi 2018-05-22 11:58:12 UTC
Description of problem:
=======================

With quota enabled on a volume, the quota used values are not updated to the list command until a lookup is done from the client mount point.

Before lookup :

# gluster v q alpha list /
                  Path                   Hard-limit  Soft-limit      Used  Available  Soft-limit exceeded? Hard-limit exceeded?
-------------------------------------------------------------------------------------------------------------------------------
/                                           N/A        N/A         0Bytes       N/A             N/A                N/A

# getfattr -d -m . /bricks/brick0/alpha-b1/d1/d2/foo10
getfattr: Removing leading '/' from absolute path names
# file: bricks/brick0/alpha-b1/d1/d2/foo10
security.selinux="system_u:object_r:glusterd_brick_t:s0"
trusted.afr.dirty=0sAAAAAAAAAAAAAAAA
trusted.gfid=0sgZRynIXvQFuWElsZo0Gd3g==
trusted.gfid2path.181b5fea80bd1afd="7171e5d4-8bef-45aa-83e8-f9e279f3977d/foo10"

After lookup :

# gluster v q alpha list /
                  Path                   Hard-limit  Soft-limit      Used  Available  Soft-limit exceeded? Hard-limit exceeded?
-------------------------------------------------------------------------------------------------------------------------------
/                                           N/A        N/A        100.0MB       N/A             N/A                N/A

# getfattr -d -m . /bricks/brick0/alpha-b1/d1/d2/foo10
getfattr: Removing leading '/' from absolute path names
# file: bricks/brick0/alpha-b1/d1/d2/foo10
security.selinux="system_u:object_r:glusterd_brick_t:s0"
trusted.afr.dirty=0sAAAAAAAAAAAAAAAA
trusted.gfid=0sgZRynIXvQFuWElsZo0Gd3g==
trusted.gfid2path.181b5fea80bd1afd="7171e5d4-8bef-45aa-83e8-f9e279f3977d/foo10"
trusted.glusterfs.quota.7171e5d4-8bef-45aa-83e8-f9e279f3977d.contri.4=0sAAAAAAAQAAAAAAAAAAAAAQ==



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

glusterfs-3.12.2-11.el7rhgs.x86_64


How reproducible:
=================

Always


Steps to Reproduce:
===================

1. Enable quota on volume
2. Mount the volume and create some directories an files from mount
3. Do "gluster volume quota volname list /"


Actual results:
===============

List shows 0Bytes as USED.


Expected results:
=================

List should show appropriate values wrt the USED value.


Additional info:

Comment 2 Sanoj Unnikrishnan 2018-05-22 12:23:19 UTC
Upstream patch link: https://review.gluster.org/20057

Comment 10 errata-xmlrpc 2018-09-04 06:48:11 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.

https://access.redhat.com/errata/RHSA-2018:2607

Comment 11 Red Hat Bugzilla 2023-09-14 04:28:34 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 1000 days