Re: [PATCH] xfs: test a regression in dquot type checking

Eryu Guan
2021-02-07T15:15:52Z

Also need _require_check_dmesg

> +
> +rm -f $seqres.full
> +
> +echo "Format filesystem" | tee -a $seqres.full
> +_scratch_mkfs > $seqres.full
> +
> +echo "Mount with project quota" | tee -a $seqres.full
> +_qmount_option 'prjquota'
> +_qmount
> +_require_prjquota $SCRATCH_DEV
> +
> +echo "Mount with group quota" | tee -a $seqres.full
> +_qmount_option 'grpquota'
> +_qmount
> +$here/src/feature -G $SCRATCH_DEV || echo "group quota didn't mount?"
> +
> +echo "Check dmesg for corruption"
> +_check_dmesg_for corruption && \
> + echo "should not have seen corruption messages"

I'd do the following to print the dmesg in question as well, so we know
what is actually failing the test.

_dmesg_since_test_start | grep corruption

A failure will look like

--- tests/xfs/527.out 2021-02-07 23:00:46.679485872 +0800
+++ /root/workspace/xfstests/results//xfs_4k/xfs/527.out.bad 2021-02-07 23:10:16.745371039 +0800
@@ -3,3 +3,5 @@
Mount with project quota
Mount with group quota
Check dmesg for corruption
+[1211043.882535] XFS (dm-5): Metadata corruption detected at xfs_dquot_from_disk+0x1b4/0x1f0 [xfs], quota 0
+[1211043.890173] XFS (dm-5): Metadata corruption detected at xfs_dquot_from_disk+0x1b4/0x1f0 [xfs], quota 0
...

I'll fix both on commit.

Thanks,
Eryu