* [PATCH] fstests: fix argument passing to _run_fsstress and _run_fsstress_bg
@ 2024-12-10 17:32 fdmanana
2024-12-12 2:31 ` Dave Chinner
2024-12-17 7:53 ` Qu Wenruo
0 siblings, 2 replies; 3+ messages in thread
From: fdmanana @ 2024-12-10 17:32 UTC (permalink / raw)
To: fstests; +Cc: linux-btrfs, dchinner, Filipe Manana
From: Filipe Manana <fdmanana@suse.com>
After commit 8973af00ec21 ("fstests: cleanup fsstress process management")
test cases btrfs/007 and btrfs/284 started to fail. For example:
$ ./check btrfs/007
FSTYP -- btrfs
PLATFORM -- Linux/x86_64 debian0 6.13.0-rc1-btrfs-next-181+ #1 SMP PREEMPT_DYNAMIC Tue Dec 3 13:03:23 WET 2024
MKFS_OPTIONS -- /dev/sdc
MOUNT_OPTIONS -- /dev/sdc /home/fdmanana/btrfs-tests/scratch_1
btrfs/007 1s ... [failed, exit status 1]- output mismatch (see /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad)
--- tests/btrfs/007.out 2020-06-10 19:29:03.810518987 +0100
+++ /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad 2024-12-10 16:09:56.345937619 +0000
@@ -1,3 +1,4 @@
QA output created by 007
*** test send / receive
-*** done
+failed: '2097152000 200'
+(see /home/fdmanana/git/hub/xfstests/results//btrfs/007.full for details)
...
(Run 'diff -u /home/fdmanana/git/hub/xfstests/tests/btrfs/007.out /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad' to see the entire diff)
Ran: btrfs/007
The problem comes from _run_fsstress and _run_fsstress_bg using $*, which
splits the string argument for the -x command used by btrfs/007, so that
fsstress gets the argument for -x as simply:
"btrfs"
Instead of:
"btrfs subvolume snapshot -r $SCRATCH_MNT $SCRATCH_MNT/base"
Fix this by using "$@" instead of $*.
Fixes: 8973af00ec21 ("fstests: cleanup fsstress process management")
Signed-off-by: Filipe Manana <fdmanana@suse.com>
---
common/rc | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/common/rc b/common/rc
index 1b2e4508..f4fff59b 100644
--- a/common/rc
+++ b/common/rc
@@ -78,13 +78,13 @@ _kill_fsstress()
_run_fsstress_bg()
{
cp -f $FSSTRESS_PROG $_FSSTRESS_PROG
- $_FSSTRESS_PROG $FSSTRESS_AVOID $* >> $seqres.full 2>&1 &
+ $_FSSTRESS_PROG $FSSTRESS_AVOID "$@" >> $seqres.full 2>&1 &
_FSSTRESS_PID=$!
}
_run_fsstress()
{
- _run_fsstress_bg $*
+ _run_fsstress_bg "$@"
_wait_for_fsstress
return $?
}
--
2.45.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] fstests: fix argument passing to _run_fsstress and _run_fsstress_bg
2024-12-10 17:32 [PATCH] fstests: fix argument passing to _run_fsstress and _run_fsstress_bg fdmanana
@ 2024-12-12 2:31 ` Dave Chinner
2024-12-17 7:53 ` Qu Wenruo
1 sibling, 0 replies; 3+ messages in thread
From: Dave Chinner @ 2024-12-12 2:31 UTC (permalink / raw)
To: fdmanana; +Cc: fstests, linux-btrfs, dchinner, Filipe Manana
On Tue, Dec 10, 2024 at 05:32:54PM +0000, fdmanana@kernel.org wrote:
> From: Filipe Manana <fdmanana@suse.com>
>
> After commit 8973af00ec21 ("fstests: cleanup fsstress process management")
> test cases btrfs/007 and btrfs/284 started to fail. For example:
>
> $ ./check btrfs/007
> FSTYP -- btrfs
> PLATFORM -- Linux/x86_64 debian0 6.13.0-rc1-btrfs-next-181+ #1 SMP PREEMPT_DYNAMIC Tue Dec 3 13:03:23 WET 2024
> MKFS_OPTIONS -- /dev/sdc
> MOUNT_OPTIONS -- /dev/sdc /home/fdmanana/btrfs-tests/scratch_1
>
> btrfs/007 1s ... [failed, exit status 1]- output mismatch (see /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad)
> --- tests/btrfs/007.out 2020-06-10 19:29:03.810518987 +0100
> +++ /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad 2024-12-10 16:09:56.345937619 +0000
> @@ -1,3 +1,4 @@
> QA output created by 007
> *** test send / receive
> -*** done
> +failed: '2097152000 200'
> +(see /home/fdmanana/git/hub/xfstests/results//btrfs/007.full for details)
> ...
> (Run 'diff -u /home/fdmanana/git/hub/xfstests/tests/btrfs/007.out /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad' to see the entire diff)
> Ran: btrfs/007
>
> The problem comes from _run_fsstress and _run_fsstress_bg using $*, which
> splits the string argument for the -x command used by btrfs/007, so that
> fsstress gets the argument for -x as simply:
>
> "btrfs"
>
> Instead of:
>
> "btrfs subvolume snapshot -r $SCRATCH_MNT $SCRATCH_MNT/base"
>
> Fix this by using "$@" instead of $*.
>
> Fixes: 8973af00ec21 ("fstests: cleanup fsstress process management")
> Signed-off-by: Filipe Manana <fdmanana@suse.com>
> ---
> common/rc | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/common/rc b/common/rc
> index 1b2e4508..f4fff59b 100644
> --- a/common/rc
> +++ b/common/rc
> @@ -78,13 +78,13 @@ _kill_fsstress()
> _run_fsstress_bg()
> {
> cp -f $FSSTRESS_PROG $_FSSTRESS_PROG
> - $_FSSTRESS_PROG $FSSTRESS_AVOID $* >> $seqres.full 2>&1 &
> + $_FSSTRESS_PROG $FSSTRESS_AVOID "$@" >> $seqres.full 2>&1 &
> _FSSTRESS_PID=$!
> }
>
> _run_fsstress()
> {
> - _run_fsstress_bg $*
> + _run_fsstress_bg "$@"
> _wait_for_fsstress
> return $?
> }
Looks good.
Reviewed-by: Dave Chinner <dchinner@redhat.com>
--
Dave Chinner
david@fromorbit.com
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] fstests: fix argument passing to _run_fsstress and _run_fsstress_bg
2024-12-10 17:32 [PATCH] fstests: fix argument passing to _run_fsstress and _run_fsstress_bg fdmanana
2024-12-12 2:31 ` Dave Chinner
@ 2024-12-17 7:53 ` Qu Wenruo
1 sibling, 0 replies; 3+ messages in thread
From: Qu Wenruo @ 2024-12-17 7:53 UTC (permalink / raw)
To: fdmanana, fstests; +Cc: linux-btrfs, dchinner, Filipe Manana
在 2024/12/11 04:02, fdmanana@kernel.org 写道:
> From: Filipe Manana <fdmanana@suse.com>
>
> After commit 8973af00ec21 ("fstests: cleanup fsstress process management")
> test cases btrfs/007 and btrfs/284 started to fail. For example:
>
> $ ./check btrfs/007
> FSTYP -- btrfs
> PLATFORM -- Linux/x86_64 debian0 6.13.0-rc1-btrfs-next-181+ #1 SMP PREEMPT_DYNAMIC Tue Dec 3 13:03:23 WET 2024
> MKFS_OPTIONS -- /dev/sdc
> MOUNT_OPTIONS -- /dev/sdc /home/fdmanana/btrfs-tests/scratch_1
>
> btrfs/007 1s ... [failed, exit status 1]- output mismatch (see /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad)
> --- tests/btrfs/007.out 2020-06-10 19:29:03.810518987 +0100
> +++ /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad 2024-12-10 16:09:56.345937619 +0000
> @@ -1,3 +1,4 @@
> QA output created by 007
> *** test send / receive
> -*** done
> +failed: '2097152000 200'
> +(see /home/fdmanana/git/hub/xfstests/results//btrfs/007.full for details)
> ...
> (Run 'diff -u /home/fdmanana/git/hub/xfstests/tests/btrfs/007.out /home/fdmanana/git/hub/xfstests/results//btrfs/007.out.bad' to see the entire diff)
> Ran: btrfs/007
>
> The problem comes from _run_fsstress and _run_fsstress_bg using $*, which
> splits the string argument for the -x command used by btrfs/007, so that
> fsstress gets the argument for -x as simply:
>
> "btrfs"
>
> Instead of:
>
> "btrfs subvolume snapshot -r $SCRATCH_MNT $SCRATCH_MNT/base"
>
> Fix this by using "$@" instead of $*.
>
> Fixes: 8973af00ec21 ("fstests: cleanup fsstress process management")
> Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: Qu Wenruo <wqu@suse.com>
Thanks,
Qu
> ---
> common/rc | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/common/rc b/common/rc
> index 1b2e4508..f4fff59b 100644
> --- a/common/rc
> +++ b/common/rc
> @@ -78,13 +78,13 @@ _kill_fsstress()
> _run_fsstress_bg()
> {
> cp -f $FSSTRESS_PROG $_FSSTRESS_PROG
> - $_FSSTRESS_PROG $FSSTRESS_AVOID $* >> $seqres.full 2>&1 &
> + $_FSSTRESS_PROG $FSSTRESS_AVOID "$@" >> $seqres.full 2>&1 &
> _FSSTRESS_PID=$!
> }
>
> _run_fsstress()
> {
> - _run_fsstress_bg $*
> + _run_fsstress_bg "$@"
> _wait_for_fsstress
> return $?
> }
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-12-17 7:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-10 17:32 [PATCH] fstests: fix argument passing to _run_fsstress and _run_fsstress_bg fdmanana
2024-12-12 2:31 ` Dave Chinner
2024-12-17 7:53 ` Qu Wenruo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox