xfs
[Top] [All Lists]

Re: [PATCH 4/8] Add test of quota accounting using fsx

To: Eric Sandeen <sandeen@xxxxxxxxxxx>
Subject: Re: [PATCH 4/8] Add test of quota accounting using fsx
From: Jan Kara <jack@xxxxxxx>
Date: Mon, 14 Jun 2010 14:46:49 +0200
Cc: Jan Kara <jack@xxxxxxx>, hch@xxxxxxxxxxxxx, xfs@xxxxxxxxxxx
In-reply-to: <4C114E80.4050803@xxxxxxxxxxx>
References: <1274710459-11446-1-git-send-email-jack@xxxxxxx> <1274710459-11446-5-git-send-email-jack@xxxxxxx> <4C0FD43D.3040803@xxxxxxxxxxx> <20100610105813.GB10827@xxxxxxxxxxxxx> <4C1117F3.2010008@xxxxxxxxxxx> <4C114E80.4050803@xxxxxxxxxxx>
User-agent: Mutt/1.5.20 (2009-06-14)
On Thu 10-06-10 15:43:44, Eric Sandeen wrote:
> Eric Sandeen wrote:
> > Jan Kara wrote:
> >> On Wed 09-06-10 12:49:49, Eric Sandeen wrote:
> >>> Jan Kara wrote:
> >>>> Run fsx (and also several fsx threads in parallel) and verify that
> >>>> quota accounting is correct after they finish.
> >>> Jan, I'm having trouble with this one on XFS for some reason, with our 
> >>> RHEL6 kernel and quota-3.17...
> 
> These don't seem to be working properly at all with xfs.
> 
> In quota-3.17, quotaoff seems to turn off both accounting and enforcement,
> despite what the man page says - 
> 
>        To turn off quota limit enforcement on any XFS filesystem, first make 
> sure
>        that quota accounting and enforcement are both turned on using 
> repquota -v
>        filesystem.   Then,  use  quotaoff -v filesystem to disable limit 
> enforce-
>        ment.  This may be done while the filesystem is mounted.
> 
> And once accounting is turned off, it can't be re-enabled without a remount.
> 
> With quota-4.0.0-preX, it seems to turn off -neither- accounting nor 
> enforcement,
> based on hch's test:
> 
> [14:59]  <hch> qemu1:~/xfstests-dev# mount -o quota /dev/vdb5 /mnt/test
> [14:59]  <hch> qemu1:~/xfstests-dev# quotaon -f /dev/vdb5
> [15:00]  <hch> qemu1:~/xfstests-dev# quotaon /dev/vdb5
> [15:00]  <hch> quotaon: Enable XFS group quota accounting during mount
> [15:00]  <hch> quotaon: Enforcing user quota already on /dev/vdb5
>                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> 
> Argh ;)
  Ah, not many people seem to use quotaon(8) with XFS :). The fact that we
turned off both enforcement and accounting was originally intended I think
(Nathan Scott wrote the code) but I agree with you that it makes more sence
to turn off just enforcement as is stated in the manpage. The check in
quotaon.c:newstate() was buggy and worked only by luck for XFS. After I
fixed error checking of kern_quota_on the check stopped working...
  I have now committed changes to quota-tools and checked that quotaon now
works reasonably with XFS so it should be cleaned up hopefully.

                                                                Honza
-- 
Jan Kara <jack@xxxxxxx>
SUSE Labs, CR

<Prev in Thread] Current Thread [Next in Thread>