Re: [PATCH 2/2] xfs: test inobtcount upgrade

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]



On Thu, Oct 29, 2020 at 01:40:23PM -0400, Brian Foster wrote:
> On Tue, Oct 27, 2020 at 12:03:48PM -0700, Darrick J. Wong wrote:
> > From: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
> > 
> > Make sure we can actually upgrade filesystems to support inobtcounts.
> > 
> > Signed-off-by: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
> > ---
> >  common/xfs        |   16 ++++++++++++
> >  tests/xfs/910     |   72 +++++++++++++++++++++++++++++++++++++++++++++++++++++
> >  tests/xfs/910.out |    3 ++
> >  tests/xfs/group   |    1 +
> >  4 files changed, 92 insertions(+)
> >  create mode 100755 tests/xfs/910
> >  create mode 100644 tests/xfs/910.out
> > 
> > 
> ...
> > diff --git a/tests/xfs/910 b/tests/xfs/910
> > new file mode 100755
> > index 00000000..1924d9ea
> > --- /dev/null
> > +++ b/tests/xfs/910
> > @@ -0,0 +1,72 @@
> ...
> > +
> > +# Now upgrade to inobtcount support
> > +_scratch_xfs_admin -O inobtcount >> $seqres.full
> > +_check_scratch_fs
> > +_scratch_xfs_db -c 'version' -c 'sb 0' -c 'p' -c 'agi 0' -c 'p' >> $seqres.full
> > +
> > +# Mount again, look at our files
> > +_scratch_mount >> $seqres.full
> > +cat $SCRATCH_MNT/urk
> > +
> 
> I think we probably want some more explicit form of validation here.
> Perhaps dump the inobt block counters from the above xfs_db command to
> the golden output..? As it is, we can comment out the xfs_admin command
> and the test still passes.

Ok.

> > +# success, all done
> > +echo Silence is golden.
> 
> We can also probably drop this if we have some other form of output from
> the test.

Will do.  Thanks for reviewing!

> Brian
> 
> > +status=0
> > +exit
> > diff --git a/tests/xfs/910.out b/tests/xfs/910.out
> > new file mode 100644
> > index 00000000..83992f49
> > --- /dev/null
> > +++ b/tests/xfs/910.out
> > @@ -0,0 +1,3 @@
> > +QA output created by 910
> > +moo
> > +Silence is golden.
> > diff --git a/tests/xfs/group b/tests/xfs/group
> > index 4b0caea4..862df3be 100644
> > --- a/tests/xfs/group
> > +++ b/tests/xfs/group
> > @@ -524,6 +524,7 @@
> >  760 auto quick rw collapse punch insert zero prealloc
> >  761 auto quick realtime
> >  763 auto quick rw realtime
> > +910 auto quick inobtcount
> >  915 auto quick quota
> >  917 auto quick db
> >  918 auto quick db
> > 
> 



[Index of Archives]     [Linux Filesystems Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux