linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dave Chinner <david-FqsqvQoI3Ljby3iVrkZq2A@public.gmane.org>
To: Andreas Dilger <adilger-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org>
Cc: "Shuichi Ihara" <sihara-LfVdkaOWEx8@public.gmane.org>,
	"Li Xi" <pkuelelixi-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	"Theodore Ts'o" <tytso-3s7WtUTddSA@public.gmane.org>,
	linux-fsdevel
	<linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	linux-ext4 <linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	"Linux API" <linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	"Jan Kara" <jack-AlSwsSmVLrQ@public.gmane.org>,
	"Al Viro"
	<viro-RmSDqhL/yNMiFSDQTTA3OLVCufUGDwFn@public.gmane.org>,
	"Christoph Hellwig" <hch-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>,
	"Дмитрий Монахов"
	<dmonakhov-GEFAQzZX7r8dnm+yROfE0A@public.gmane.org>,
	"Shuichi Ihara" <ihashu-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: Re: [v15 0/4] ext4: add project quota support
Date: Mon, 23 Nov 2015 13:50:14 +1100	[thread overview]
Message-ID: <20151123025014.GK19199@dastard> (raw)
In-Reply-To: <951D56EE-D6DD-47BA-8AFA-A7D43E96D1E4-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org>

On Sun, Nov 22, 2015 at 06:45:24PM -0700, Andreas Dilger wrote:
> On Nov 19, 2015, at 2:47 PM, Dave Chinner <david-FqsqvQoI3Ljby3iVrkZq2A@public.gmane.org> wrote:
> > 
> > On Wed, Nov 18, 2015 at 02:14:32PM +0000, Shuichi Ihara wrote:
> >> 
> >> 11/9/15, 6:28 AM , "Dave Chinner" <david-FqsqvQoI3Ljby3iVrkZq2A@public.gmane.org> wrote:
> >> 
> >>> On Thu, Nov 05, 2015 at 03:13:10PM +0000, Shuichi Ihara wrote:
> >>>> Hello Ted, Andreas,
> >>>> 
> >>>> Shilong posted an email here a week ago below.
> >>>> http://lists.openwall.net/linux-ext4/2015/10/30/2
> >>>> 
> >>>> we identified 10 project quota related xfstest and ported them into ext4/xxx.
> >>>> test number are 304, 305, 299, 244, 196, 134, 108, 107, 106, 050 in xfs.
> >>>> 
> >>>> 
> >>>> We ported 9/10 tests into ext4/xxx
> >>>> ext4/050 ext4/106 ext4/107 ext4/108 ext4/196 ext4/244 ext4/299 ext4/400 ext4/401
> >>> 
> >>> Please make them generic tests - the ext4 project quota
> >>> functioanlity should work with those tests being completely
> >>> unchanged except for a "_requires_project_quota()" function...
> >> 
> >> Right now, we enhanced quotatool to support project quota and above project quota tests in ext4 uses that interface.
> >> xfs uses own interface xfs_xx for project quota tests in xfs.
> >> what interface are you looking at if we move ext4's project quota tests into generic tests?
> > 
> > The project quota support in the generic quota tool should work XFS
> > as well as ext4. If it doesn't, then it's not a generic tool, right?
> > The whole point of having ext4 use the same userspace API as XFS is
> > so that all quotas can be managed with the one tool. Essentially, if
> > ext4 project quotas cannot be controlled by xfs_quota, then the ext4
> > code is not compatible with XFS and hence still needs work.
> > 
> > FWIW, if ext4 has implemented the kernel project quota interfaces
> > correctly, then it should not matter whether we use xfs_quota or the
> > generic quotatool because the kernel will translate the filesystem
> > information to whatever format the quota was requested in...
> > 
> > So, you should be able to simply use the xfs_quota tool in the tests
> > you make generic without needing any significant modification to the
> > tests to run them on ext4. Yes, that may mean you need to send a 5
> > line patch to make xfs_quota run on ext4, but that's trivial
> > compared to duplicating >10 tests and then having to maintain them
> > forever...
> 
> I think it also makes sense to have tests for the generic quota tools,
> which is what current ext4 users will have installed, and not just
> xfs_quota.  This applies to both ext4 and xfs using the generic quota
> tools with the new interface.

Yes, I said as much: "... it should not matter whether we use
xfs_quota or the generic quotatool ....". I've been saying that tool
compability is an absolute requirement for the ext4 project quota
implementation from the very start - I'm not about to say it doesn't
matter now.

Yes, eventually we need to have tests for the generic quotatool,
but only having generic quotatool tests run only on ext4 does not
prove anything about the compatibility of the new ext4 kernel code
with the pre-existing quota tools and kernel APIs.

> In that light, it makes sense to add
> new tests that use the new quota tools, in addition to testing xfs_quota
> on XFS and ext4.

The first step is not "duplicate all the tests with different
infrastructure as new one-filesystem-only specific tests".  We need
to ensure the APIs are compatible *before merging the kernel code*,
and these tests do no do that.

IOWs, like all the other tests we've made generic for kernel
functionality we've moved from XFS to generic code, the steps are:

	1. move the tests from tests/xfs to tests/generic
	2. make the xfs specific utilities work on non XFS
	   filesystems and, if necessary, use the new generic kernel
	   API.
	3. make the tests also run and passwork on non-XFS filesystems

	[ at this point we can say the new ext4 kernel code is good to
	  commit ]

	4. factor the generic tests so that the test core is
	   independent of the infrastructure that needs testing
	5. Duplicate the generic tests *as generic tests* using the
	   different tools that need testing /or/ make the
	   tooling selectable by environment/config file
	   variables.

After step 5, we should have tests that run on multiple filesystems
using multiple tools, and they all give the same results. The tests
as proposed don't provide us with any guarantee that the generic
quota tool will work on XFS, nor that ext4 has an API that is
compatible with XFS.

Cheers,

Dave.
-- 
Dave Chinner
david-FqsqvQoI3Ljby3iVrkZq2A@public.gmane.org

  parent reply	other threads:[~2015-11-23  2:50 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-13 12:20 [v15 0/4] ext4: add project quota support Li Xi
     [not found] ` <1442146833-13652-1-git-send-email-lixi-LfVdkaOWEx8@public.gmane.org>
2015-09-13 12:20   ` [v15 1/4] ext4: adds project ID support Li Xi
     [not found]     ` <1442146833-13652-2-git-send-email-lixi-LfVdkaOWEx8@public.gmane.org>
2015-09-23 12:34       ` Dmitry Monakhov
2015-09-23 18:17         ` Jan Kara
2015-09-13 12:20   ` [v15 2/4] ext4: adds project quota support Li Xi
2015-09-24 17:12   ` [v15 0/4] ext4: add " Andreas Dilger
2015-11-05 14:45     ` Li Xi
2015-11-05 15:13       ` Shuichi Ihara
     [not found]         ` <7360A48E-8576-49DB-878B-DFC2EFC83BC4-LfVdkaOWEx8@public.gmane.org>
2015-11-08 21:28           ` Dave Chinner
2015-11-18 14:14             ` Shuichi Ihara
2015-11-19 21:47               ` Dave Chinner
2015-11-23  1:45                 ` Andreas Dilger
     [not found]                   ` <951D56EE-D6DD-47BA-8AFA-A7D43E96D1E4-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org>
2015-11-23  2:50                     ` Dave Chinner [this message]
2015-11-23  9:25                 ` Jan Kara
     [not found]                   ` <20151123092523.GB23418-+0h/O2h83AeN3ZZ/Hiejyg@public.gmane.org>
2015-11-23 20:15                     ` Dave Chinner
2015-11-24  9:07                       ` Jan Kara
2015-09-13 12:20 ` [v15 3/4] ext4: adds FS_IOC_FSSETXATTR/FS_IOC_FSGETXATTR interface support Li Xi
2016-01-03 23:05   ` [PATCH] fs: XFS_IOC_FS[SG]SETXATTR to FS_IOC_FS[SG]ETXATTR promotion Dave Chinner
2016-01-04  6:15     ` Theodore Ts'o
2016-01-30  0:56     ` Pranith Kumar
     [not found]       ` <CAJhHMCAvTJj=bX=uE1oK+DzG8aGNGvM-BkY83+H4BgzQiNBa+A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-01-30  4:41         ` Theodore Ts'o
2016-01-30  4:49           ` Pranith Kumar
2016-01-31 22:36             ` Dave Chinner
2015-09-13 12:20 ` [v15 4/4] ext4: cleanup inode flag definitions Li Xi
     [not found]   ` <1442146833-13652-5-git-send-email-lixi-LfVdkaOWEx8@public.gmane.org>
2015-12-28 15:23     ` Theodore Ts'o
2015-09-23 12:31 ` [v15 0/4] ext4: add project quota support Jan Kara
     [not found]   ` <20150923123119.GA13946-+0h/O2h83AeN3ZZ/Hiejyg@public.gmane.org>
2015-09-23 13:17     ` Li Xi
     [not found]       ` <CAPTn0cBB7h89R7NB+zg+J+TVvKXut_Usixs==S=AWs-v7kZExg-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-09-23 13:32         ` Dmitry Monakhov
2015-09-23 13:57           ` Li Xi
     [not found]             ` <CAPTn0cC=1xWCcUMVqhAx4pvqqX9rXC8p6B4Jt7cpm4HfuaFOMw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-09-23 13:58               ` Li Xi
2015-09-23 14:13               ` Dmitry Monakhov
2015-09-24 12:09             ` Jan Kara
2015-10-18  1:01 ` Theodore Ts'o
2015-10-18  2:25   ` Li Xi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20151123025014.GK19199@dastard \
    --to=david-fqsqvqoi3ljby3ivrkzq2a@public.gmane.org \
    --cc=adilger-m1MBpc4rdrD3fQ9qLvQP4Q@public.gmane.org \
    --cc=dmonakhov-GEFAQzZX7r8dnm+yROfE0A@public.gmane.org \
    --cc=hch-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
    --cc=ihashu-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=jack-AlSwsSmVLrQ@public.gmane.org \
    --cc=linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=pkuelelixi-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=sihara-LfVdkaOWEx8@public.gmane.org \
    --cc=tytso-3s7WtUTddSA@public.gmane.org \
    --cc=viro-RmSDqhL/yNMiFSDQTTA3OLVCufUGDwFn@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).