* [PATCH] fstests: btrfs/021: redirect the output of defrag command
@ 2022-11-13 2:08 Qu Wenruo
2022-11-14 10:33 ` Filipe Manana
0 siblings, 1 reply; 2+ messages in thread
From: Qu Wenruo @ 2022-11-13 2:08 UTC (permalink / raw)
To: linux-btrfs, fstests
[BUG]
Test case btrfs/021 will fail with v6.0 btrfs-progs, with the extra
output:
QA output created by 021
+/mnt/scratch/padding-0
+/mnt/scratch/padding-1
+/mnt/scratch/padding-2
+/mnt/scratch/padding-3
+/mnt/scratch/padding-4
+/mnt/scratch/padding-5
...
[CAUSE]
In fact this is a btrfs-progs bug, btrfs-progs commit db2f85c8751c
("btrfs-progs: fi defrag: add global verbose option") changed the output
level of defrag command.
[FIX]
This will be fixed in btrfs-progs, while as a workaround we can redirect
the stdout into $seqres.full.
If we hit some error, the stderr will still pollute the golden output
and be caught by the test case.
Signed-off-by: Qu Wenruo <wqu@suse.com>
---
tests/btrfs/021 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/btrfs/021 b/tests/btrfs/021
index 5943da2f..6b6383cb 100755
--- a/tests/btrfs/021
+++ b/tests/btrfs/021
@@ -23,7 +23,7 @@ run_test()
sleep 0.5
find $SCRATCH_MNT -type f -print0 | xargs -0 \
- $BTRFS_UTIL_PROG filesystem defrag -f
+ $BTRFS_UTIL_PROG filesystem defrag -f >> $seqres.full
sync
wait
--
2.38.0
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] fstests: btrfs/021: redirect the output of defrag command
2022-11-13 2:08 [PATCH] fstests: btrfs/021: redirect the output of defrag command Qu Wenruo
@ 2022-11-14 10:33 ` Filipe Manana
0 siblings, 0 replies; 2+ messages in thread
From: Filipe Manana @ 2022-11-14 10:33 UTC (permalink / raw)
To: Qu Wenruo; +Cc: linux-btrfs, fstests
On Sun, Nov 13, 2022 at 2:31 AM Qu Wenruo <wqu@suse.com> wrote:
>
> [BUG]
> Test case btrfs/021 will fail with v6.0 btrfs-progs, with the extra
> output:
>
> QA output created by 021
> +/mnt/scratch/padding-0
> +/mnt/scratch/padding-1
> +/mnt/scratch/padding-2
> +/mnt/scratch/padding-3
> +/mnt/scratch/padding-4
> +/mnt/scratch/padding-5
> ...
>
> [CAUSE]
> In fact this is a btrfs-progs bug, btrfs-progs commit db2f85c8751c
> ("btrfs-progs: fi defrag: add global verbose option") changed the output
> level of defrag command.
>
> [FIX]
> This will be fixed in btrfs-progs, while as a workaround we can redirect
> the stdout into $seqres.full.
>
> If we hit some error, the stderr will still pollute the golden output
> and be caught by the test case.
>
> Signed-off-by: Qu Wenruo <wqu@suse.com>
> ---
> tests/btrfs/021 | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tests/btrfs/021 b/tests/btrfs/021
> index 5943da2f..6b6383cb 100755
> --- a/tests/btrfs/021
> +++ b/tests/btrfs/021
> @@ -23,7 +23,7 @@ run_test()
> sleep 0.5
>
> find $SCRATCH_MNT -type f -print0 | xargs -0 \
> - $BTRFS_UTIL_PROG filesystem defrag -f
> + $BTRFS_UTIL_PROG filesystem defrag -f >> $seqres.full
Already sent a fix for this last week (plus this misses btrfs/256):
https://lore.kernel.org/fstests/e393451cb53b6b81804eaa41c6461b07a910eb62.1668011769.git.fdmanana@suse.com/
Thanks.
>
> sync
> wait
> --
> 2.38.0
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-11-14 10:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-13 2:08 [PATCH] fstests: btrfs/021: redirect the output of defrag command Qu Wenruo
2022-11-14 10:33 ` Filipe Manana
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox