Skip to contentSkip to conversation

generic/388: use the src/godown program instead of xfs_io

PATCH In review Theodore Ts'o 2 participants 2 messages Feb 3, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 generic/388: use the src/godown program instead of xfs_io

The "xfs_io -xc shutdown $MNT" command doesn't work on non-xfs file systems. So use the equivalent src/godown program instead, which is how the other tests which use the shutdown command were converted from xfs-specific tests to generic tests.

---
 tests/generic/388 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/generic/388 +1 -1
index c00a7548..9d4ba9d6 100755
@@ -71,7 +71,7 @@ for i in $(seq 1 50); do
 	# purposely include 0 second sleeps to test shutdown immediately after
 	# recovery
 	sleep $((RANDOM % 3))
-	$XFS_IO_PROG -xc shutdown $SCRATCH_MNT
+	./src/godown $SCRATCH_MNT
 
 	ps -e | grep fsstress > /dev/null 2>&1
 	while [ $? -eq 0 ]; do
Signature · 1 line
2.11.0.rc0.7.gbe5a750
Reviewed-by on v1 1/1
#1 lore raw
Quoted 15 lines · Theodore Ts'o

The "xfs_io -xc shutdown $MNT" command doesn't work on non-xfs file systems. So use the equivalent src/godown program instead, which is how the other tests which use the shutdown command were converted from xfs-specific tests to generic tests.

---
 tests/generic/388 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
tests/generic/388 +0 -0
index c00a7548..9d4ba9d6 100755

tests/generic/388 for i in $(seq 1 50); do · line 74

Quoted 5 lines
tests/generic/388 +1 -1
@@ -71,7 +71,7 @@ for i in $(seq 1 50); do
 	# purposely include 0 second sleeps to test shutdown immediately after
 	# recovery
 	sleep $((RANDOM % 3))
-	$XFS_IO_PROG -xc shutdown $SCRATCH_MNT
+	./src/godown $SCRATCH_MNT

Looks ok,

Though to avoid inconsistency I recommend sending an xfsprogs patch adding CMD_FLAG_FOREIGN_OK to the shutdown command once support lands in ext4.

--D

Quoted 10 lines
tests/generic/388 +0 -0
 	ps -e | grep fsstress > /dev/null 2>&1
 	while [ $? -eq 0 ]; do
Signature · 6 lines
2.11.0.rc0.7.gbe5a750

--
To unsubscribe from this list: send the line "unsubscribe fstests" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html