Bug 1202244

Summary: [Quota] : To have a separate quota.conf file for inode quota.
Product: [Community] GlusterFS Reporter: Sachin Pandit <spandit>
Component: quotaAssignee: Nagaprasad Sathyanarayana <nsathyan>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: mainlineCC: bugs, gluster-bugs, nsathyan, smohan, vmallika
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: quota
Fixed In Version: glusterfs-3.8rc2 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1218170 (view as bug list) Environment:
Last Closed: 2016-06-16 12:43:55 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: 1190108    
Bug Blocks: 1186580, 1218170    

Description Sachin Pandit 2015-03-16 08:23:56 UTC
Description of problem:
Currently we maintain the quota configuration in a file called
quota.conf which is present in /var/lib/gluster/vols/<volname>

With introduction of inode quota, we have to save the configuration
related to inode quota in a file too. If we have the same file to
service both existing quota and inode quota we might end up in the
below mentioned problem:

* quota conf is a place holder to save gfid of the directory where
  quota limit is set.
* The problem occurs when we try to remove a limit on some directory.
  As we now have two types of quota we cant distinguish between the
  type by having gfid alone.


Possible solution:
1) Currently we maintain a 16byte gfid, we can save 1 byte extra
   along with gfid that to distinguish b/w existing quota and inode quota
2) TO have a separate quota.conf file altogether for inode quotas

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


How reproducible:
1/1

Steps to Reproduce:
1. Set a usage limit on directory " gluster volume quota <volname> limit-usage <directory> <size>
2. Set a inode quota limit on directory "gluster volume quota <volname> limit-objects <directory> <limit>
3. remove the limit on usage on directory
4. test the inode quota list "gluster volume quota vol1 list-objects

Actual results:
inode quota is also removed if we remove usage quota.

Expected results:
inode quota should not be effected by usage quota.

Additional info:

Comment 1 Anand Avati 2015-03-16 12:07:40 UTC
REVIEW: http://review.gluster.org/9900 (features/quota : Have a separate conf and cksum for inode quota limits) posted (#1) for review on master by Sachin Pandit (spandit)

Comment 2 Anand Avati 2015-04-15 13:59:33 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quotas in quota.conf) posted (#2) for review on master by Vijaikumar Mallikarjuna (vmallika)

Comment 3 Anand Avati 2015-04-15 14:14:58 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quotas in quota.conf) posted (#3) for review on master by Vijaikumar Mallikarjuna (vmallika)

Comment 4 Anand Avati 2015-04-16 02:20:44 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quotas in quota.conf) posted (#4) for review on master by Vijaikumar Mallikarjuna (vmallika)

Comment 5 Anand Avati 2015-04-16 07:40:00 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quotas in quota.conf) posted (#5) for review on master by Vijaikumar Mallikarjuna (vmallika)

Comment 6 Anand Avati 2015-04-24 06:06:00 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quota in quota.conf) posted (#6) for review on master by Sachin Pandit (spandit)

Comment 7 Anand Avati 2015-04-24 07:12:25 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quota in quota.conf) posted (#7) for review on master by Sachin Pandit (spandit)

Comment 8 Anand Avati 2015-04-27 05:33:41 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quota in quota.conf) posted (#8) for review on master by Sachin Pandit (spandit)

Comment 9 Anand Avati 2015-04-27 09:34:51 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quota in quota.conf) posted (#9) for review on master by Sachin Pandit (spandit)

Comment 10 Anand Avati 2015-04-27 15:11:43 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quota in quota.conf) posted (#10) for review on master by Sachin Pandit (spandit)

Comment 11 Anand Avati 2015-04-28 06:35:16 UTC
REVIEW: http://review.gluster.org/10069 (quota: support for inode quota in quota.conf) posted (#11) for review on master by Sachin Pandit (spandit)

Comment 12 Anand Avati 2015-05-05 03:08:51 UTC
REVIEW: http://review.gluster.org/10539 (tests: Unmount aux quota mount) posted (#1) for review on master by Pranith Kumar Karampuri (pkarampu)

Comment 13 Anand Avati 2015-05-05 03:20:10 UTC
REVIEW: http://review.gluster.org/10540 (cleanup: Unmount all fuse mounts) posted (#1) for review on master by Pranith Kumar Karampuri (pkarampu)

Comment 14 Anand Avati 2015-05-05 09:17:43 UTC
COMMIT: http://review.gluster.org/10539 committed in master by Vijay Bellur (vbellur) 
------
commit 9ddea81a3b6f557c899c90ec84ac8463616e0bc5
Author: Pranith Kumar K <pkarampu>
Date:   Tue May 5 08:31:39 2015 +0530

    tests: Unmount aux quota mount
    
    Change-Id: Ie4ec40230e6b92d2e694b804a991246050b5fa51
    BUG: 1202244
    Signed-off-by: Pranith Kumar K <pkarampu>
    Reviewed-on: http://review.gluster.org/10539
    Tested-by: Gluster Build System <jenkins.com>
    Tested-by: NetBSD Build System
    Reviewed-by: Sachin Pandit <spandit>

Comment 17 Nagaprasad Sathyanarayana 2015-10-25 15:21:11 UTC
Fix for this BZ is already present in a GlusterFS release. You can find clone of this BZ, fixed in a GlusterFS release and closed. Hence closing this mainline BZ as well.

Comment 18 Niels de Vos 2016-06-16 12:43:55 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.8.0, please open a new bug report.

glusterfs-3.8.0 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] http://blog.gluster.org/2016/06/glusterfs-3-8-released/
[2] http://thread.gmane.org/gmane.comp.file-systems.gluster.user