]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commit
btrfs/003: fix failure on new btrfs-progs versions
authorFilipe Manana <fdmanana@suse.com>
Wed, 9 Nov 2022 16:44:56 +0000 (16:44 +0000)
committerZorro Lang <zlang@kernel.org>
Wed, 23 Nov 2022 03:55:03 +0000 (11:55 +0800)
commit7e0d5f6a44368ffa269d91856994da6d93a4eb9b
tree7eedf2c367871a49f3264be515651c0548c03578
parent4b480aae3ed127aa675582e3baad14aa969ee1dc
btrfs/003: fix failure on new btrfs-progs versions

Starting with btrfs-progs version 5.19, the output of 'filesystem show'
command changed when we have a missing device. The old output was like the
following:

    Label: none  uuid: 139ef309-021f-4b98-a3a8-ce230a83b1e2
            Total devices 2 FS bytes used 128.00KiB
            devid    1 size 5.00GiB used 1.26GiB path /dev/loop0
            *** Some devices missing

While the new output (btrfs-progs 5.19+) is like the following:

    Label: none  uuid: 4a85a40b-9b79-4bde-8e52-c65a550a176b
            Total devices 2 FS bytes used 128.00KiB
            devid    1 size 5.00GiB used 1.26GiB path /dev/loop0
            devid    2 size 0 used 0 path /dev/loop1 MISSING

More specifically it happened in the following btrfs-progs commit:

    957a79c9b016 ("btrfs-progs: fi show: print missing device for a mounted file system")

This is making btrfs/003 fail with btrfs-progs 5.19+. Update the grep
filter in btrfs/003 so that it works with both output formats.

Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: Zorro Lang <zlang@redhat.com>
Signed-off-by: Zorro Lang <zlang@kernel.org>
tests/btrfs/003