From b5ba77147bf6cf6766ada00b3fed4635626e550d Mon Sep 17 00:00:00 2001 From: "Darrick J. Wong" Date: Mon, 13 Nov 2023 09:08:30 -0800 Subject: xfs: test unlinked inode list repair on demand Create a test to exercise recovery of unlinked inodes on a clean filesystem. This was definitely possible on old kernels that on an ro mount would clean the log without processing the iunlink list. Signed-off-by: "Darrick J. Wong" Reviewed-by: Zorro Lang Signed-off-by: Zorro Lang --- common/rc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'common') diff --git a/common/rc b/common/rc index e64dea10..cc92fe06 100644 --- a/common/rc +++ b/common/rc @@ -2668,9 +2668,11 @@ _require_xfs_io_command() param_checked="$pwrite_opts $param" ;; "scrub"|"repair") - testio=`$XFS_IO_PROG -x -c "$command probe" $TEST_DIR 2>&1` + test -z "$param" && param="probe" + testio=`$XFS_IO_PROG -x -c "$command $param" $TEST_DIR 2>&1` echo $testio | grep -q "Inappropriate ioctl" && \ _notrun "xfs_io $command support is missing" + param_checked="$param" ;; "startupdate"|"commitupdate"|"cancelupdate") $XFS_IO_PROG -f -c 'pwrite -S 0x58 0 128k -b 128k' $testfile > /dev/null -- cgit v1.2.3