]> git-server-git.apps.pok.os.sepia.ceph.com Git - xfsprogs-dev.git/commitdiff
xfs_scrub_all: fix non-service-mode arguments to xfs_scrub
authorDarrick J. Wong <djwong@kernel.org>
Mon, 2 Feb 2026 19:14:05 +0000 (11:14 -0800)
committerAndrey Albershteyn <aalbersh@kernel.org>
Tue, 3 Feb 2026 08:47:39 +0000 (09:47 +0100)
Back in commit 7da76e2745d6a7, we changed the default arguments to
xfs_scrub for the xfs_scrub@ service to derive the fix/preen/check mode
from the "autofsck" filesystem property instead of hardcoding "-p".
Unfortunately, I forgot to make the same update for xfs_scrub_all being
run from the CLI and directly invoking xfs_scrub.

Link: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1125314
Cc: linux-xfs@vger.kernel.org # v6.10.0
Fixes: 7da76e2745d6a7 ("xfs_scrub: use the autofsck fsproperty to select mode")
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
scrub/Makefile
scrub/xfs_scrub_all.py.in

index 6375d77a291bcb5c65b7a5ebca8ae43ee839ef07..ff79a265762332e6d6ba8a3b00ea1bb32b998b0b 100644 (file)
@@ -16,7 +16,7 @@ LTCOMMAND = xfs_scrub
 INSTALL_SCRUB = install-scrub
 XFS_SCRUB_ALL_PROG = xfs_scrub_all.py
 XFS_SCRUB_FAIL_PROG = xfs_scrub_fail
-XFS_SCRUB_ARGS = -p
+XFS_SCRUB_ARGS = -o autofsck
 XFS_SCRUB_SERVICE_ARGS = -b -o autofsck
 ifeq ($(HAVE_SYSTEMD),yes)
 INSTALL_SCRUB += install-systemd
index ce251daea6a5d54dc514ce6b458cad116d79b5ba..9f861639a43ce480f80cb7c701309b9559d0bc45 100644 (file)
@@ -102,7 +102,8 @@ class scrub_subprocess(scrub_control):
                cmd = ['@sbindir@/xfs_scrub']
                if 'SERVICE_MODE' in os.environ:
                        cmd += '@scrub_service_args@'.split()
-               cmd += '@scrub_args@'.split()
+               else:
+                       cmd += '@scrub_args@'.split()
                if scrub_media:
                        cmd += '-x'
                cmd += [mnt]