From: "Darrick J. Wong" <darrick.wong@oracle.com>
To: Eryu Guan <eguan@redhat.com>
Cc: ocfs2-devel@oss.oracle.com, fstests@vger.kernel.org
Subject: Re: [PATCH 3/7] reflink: fix quota tests to work properly
Date: Mon, 12 Dec 2016 15:08:37 -0800 [thread overview]
Message-ID: <20161212230837.GH25841@birch.djwong.org> (raw)
In-Reply-To: <20161212100622.GZ29149@eguan.usersys.redhat.com>
On Mon, Dec 12, 2016 at 06:06:22PM +0800, Eryu Guan wrote:
> On Sun, Dec 11, 2016 at 01:53:04PM -0800, Darrick J. Wong wrote:
> > Fix the reflink quota tests to su to the fsgqa user so that we actually
> > test enforcement of quotas. Seems that XFS enforces user quotas even
> > if root is writing to a user file, whereas everything else lets root
> > writes through. Also clean up some of the variable usage and
> > _require_user.
> >
> > Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
> > ---
> > tests/generic/305 | 2 +-
> > tests/generic/305.out | 30 +++++++++++++++---------------
> > tests/generic/326 | 2 +-
> > tests/generic/326.out | 30 +++++++++++++++---------------
> > tests/generic/327 | 12 +++++++-----
> > tests/generic/327.out | 12 ++++++------
> > tests/generic/328 | 14 ++++++++------
> > tests/generic/328.out | 28 ++++++++++++++--------------
> > 8 files changed, 67 insertions(+), 63 deletions(-)
> >
> >
> > diff --git a/tests/generic/305 b/tests/generic/305
> > index d73d87f..9c3489b 100755
> > --- a/tests/generic/305
> > +++ b/tests/generic/305
> > @@ -51,7 +51,7 @@ _require_quota
> > _require_nobody
> >
> > _repquota() {
> > - repquota $SCRATCH_MNT | egrep '^(fsgqa|root|nobody)'
> > + repquota -O csv $SCRATCH_MNT | egrep '^(fsgqa|root|nobody)' | awk -F ',' '{print $1, $4, $5, $6}'
>
> The version of "quota" is a bit old shipped by RHEL7, there's no "-O"
> option support. And this works for me
>
> repquota $SCRATCH_MNT | egrep '^(fsgqa|root|nobody)' | awk '{print $1, $3, $4, $5}'
>
> Still worth chaning the .out files this way?
Yes, because the inode usage counts aren't guaranteed to be the same
between filesystems due to weirdness in the root inode counts.
Basically, ocfs2 charges an additional 2 root inode count right off the
bat, which screws up the golden output. btrfs doesn't have user/group
quotas, so the reflink-quota tests only ever checked XFS in the past.
I'll fix it not to rely on -O csv.
--D
>
> Thanks,
> Eryu
> --
> To unsubscribe from this list: send the line "unsubscribe fstests" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2016-12-12 23:08 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-12-11 21:52 [PATCH 0/7] xfstests: misc reflink test fixes Darrick J. Wong
2016-12-11 21:52 ` [PATCH 1/7] ocfs2: test reflinking to inline data files Darrick J. Wong
2016-12-12 9:01 ` Eryu Guan
2016-12-12 18:09 ` Darrick J. Wong
2016-12-13 3:20 ` Eryu Guan
2016-12-13 7:11 ` Darrick J. Wong
2016-12-13 21:35 ` Darrick J. Wong
2016-12-14 7:32 ` Eric Ren
2016-12-11 21:52 ` [PATCH 2/7] ocfs2/reflink: fix file block size reporting Darrick J. Wong
2016-12-12 9:48 ` Eryu Guan
2016-12-12 23:08 ` Darrick J. Wong
2016-12-11 21:53 ` [PATCH 3/7] reflink: fix quota tests to work properly Darrick J. Wong
2016-12-12 10:06 ` Eryu Guan
2016-12-12 23:08 ` Darrick J. Wong [this message]
2016-12-11 21:53 ` [PATCH 4/7] reflink: fix space consumption tests Darrick J. Wong
2016-12-12 10:25 ` Eryu Guan
2016-12-12 23:03 ` Darrick J. Wong
2016-12-13 3:22 ` Eryu Guan
2016-12-11 21:53 ` [PATCH 5/7] reflink: make error reporting consistent Darrick J. Wong
2016-12-12 10:47 ` Eryu Guan
2016-12-12 23:06 ` Darrick J. Wong
2016-12-11 21:53 ` [PATCH 6/7] reflink: don't test disjoint block sharing sets Darrick J. Wong
2016-12-11 21:53 ` [PATCH 7/7] xfs/ext4: check negative inode size Darrick J. Wong
2016-12-12 11:07 ` Eryu Guan
2016-12-13 21:49 ` Darrick J. Wong
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=20161212230837.GH25841@birch.djwong.org \
--to=darrick.wong@oracle.com \
--cc=eguan@redhat.com \
--cc=fstests@vger.kernel.org \
--cc=ocfs2-devel@oss.oracle.com \
/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