xfstests: test quota log replay in 087
RFC PATCH 1/1 xfstests: test quota log replay in 087
By mounting the filesystem with quotas enabled in 087 we exercise the replay of the quota log items in this tests, which we otherwise don't test in xfstests. OSS bugzilla #855 is an example of something caught by this.
Does this look okay, or should I add a duplicate of 087 with quotas enabled instead?
087 +4 -2
@@ -38,6 +38,7 @@ trap "rm -f $tmp.*; exit \$status" 0 1 2 . ./common.rc . ./common.filter . ./common.log +. ./common.quota _do_meta() {
@@ -59,6 +60,7 @@ _supported_os IRIX Linux rm -f $seq.full $tmp.* _require_scratch _require_v2log +_require_xfs_quota echo "*** init FS" umount $SCRATCH_DEV >/dev/null 2>&1
@@ -98,7 +100,7 @@ do # mount the FS _echofull "mount" - if ! _scratch_mount >>$seq.full 2>&1; then + if ! _scratch_mount -o uquota >>$seq.full 2>&1; then _echofull "mount failed: $MOUNT_OPTIONS" continue fi
@@ -124,7 +126,7 @@ do _scratch_xfs_logprint -n >>$seq.full 2>&1 _echofull "mount with replay" - _scratch_mount >>$seq.full 2>&1 \ + _scratch_mount -o uquota >>$seq.full 2>&1 \ || _fail "mount failed: $MOUNT_OPTIONS" # check on what FS looks like after log recovery
group +1 -1
@@ -193,7 +193,7 @@ prealloc 084 ioctl rw auto 085 log auto quick 086 log v2log auto -087 log v2log auto +087 log v2log auto quota 088 perms auto quick 089 metadata auto 090 rw auto
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Quoted 7 lines · Christoph Hellwig
By mounting the filesystem with quotas enabled in 087 we exercise the replay of the quota log items in this tests, which we otherwise don't test in xfstests. OSS bugzilla #855 is an example of something caught by this.
Does this look okay, or should I add a duplicate of 087 with quotas enabled instead?
I think having 087 cover quotas as well is fine. Adding a separate test just for quotas doesn't provide any extra coverage compared to this patch.
087 do · line 103
Quoted 6 lines
087 +1
-1@@ -98,7 +100,7 @@ do # mount the FS _echofull "mount" - if ! _scratch_mount >>$seq.full 2>&1; then + if ! _scratch_mount -o uquota >>$seq.full 2>&1; then
My only question is whether this will work if uquota is set up as a global option. I haven't looked into it yet, but there appears to be several different ways that uquota is specified in other tests:
052:_qmount_option uquota
108:export MOUNT_OPTIONS="-ouquota"
116:mount -o uquota $SCRATCH_DEV $SCRATCH_MNT
220:_scratch_mount -o uquota
Some consistency would be nice, but I don't think it's a problem for this patch right now.
Signature · 7 lines
Dave Chinner [email protected] _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs