]> git-server-git.apps.pok.os.sepia.ceph.com Git - xfstests-dev.git/commitdiff
xfs/432: fix this test when external devices are in use
authorDarrick J. Wong <djwong@kernel.org>
Wed, 3 Aug 2022 04:21:26 +0000 (21:21 -0700)
committerZorro Lang <zlang@kernel.org>
Fri, 5 Aug 2022 16:57:22 +0000 (00:57 +0800)
This program exercises metadump and mdrestore being run against the
scratch device.  Therefore, the test must pass external log / rt device
arguments to xfs_repair -n to check the "restored" filesystem.  Fix the
incorrect usage, and report repair failures, since this test has been
silently failing for a while now.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Zorro Lang <zlang@redhat.com>
Signed-off-by: Zorro Lang <zlang@kernel.org>
tests/xfs/432

index 86012f0b0c34b284eb0ad86cf08101e1d005e154..e1e610d0541110261a09a2e43e8b660f18404bb4 100755 (executable)
@@ -89,7 +89,8 @@ _scratch_xfs_metadump $metadump_file -w
 xfs_mdrestore $metadump_file $metadump_img
 
 echo "Check restored metadump image"
-$XFS_REPAIR_PROG -n $metadump_img >> $seqres.full 2>&1
+SCRATCH_DEV=$metadump_img _scratch_xfs_repair -n &>> $seqres.full || \
+       echo "xfs_repair on restored fs returned $?"
 
 # success, all done
 status=0