xfs: only run scrub in dry run mode
authorDarrick J. Wong <darrick.wong@oracle.com>
Fri, 21 Jul 2017 22:04:27 +0000 (15:04 -0700)
committerEryu Guan <eguan@redhat.com>
Thu, 3 Aug 2017 12:44:04 +0000 (20:44 +0800)
When checking a filesystem, explicitly run xfs_scrub in dry run mode
so that it will not ever try to preen, fix, or optimize anything.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
common/xfs

index a1ee384786bb69c09737463eb32ac49a12458e88..fd04f65f6e25e720a8dd27aa9cc04ade25944048 100644 (file)
@@ -331,7 +331,7 @@ _check_xfs_filesystem()
 
        if [ "$type" = "xfs" ]; then
                if [ -n "$TEST_XFS_SCRUB" ] && [ -x "$XFS_SCRUB_PROG" ]; then
-                       "$XFS_SCRUB_PROG" $scrubflag -vd $device >>$seqres.full
+                       "$XFS_SCRUB_PROG" $scrubflag -v -d -n $device >>$seqres.full
                        if [ $? -ne 0 ]; then
                                _log_err "filesystem on $device failed scrub"
                                ok=0