qemu-e2k/tests/qemu-iotests/tests
Eric Blake 955171e441 qemu-img: Add --skip-broken-bitmaps for 'convert --bitmaps'
The point of 'qemu-img convert --bitmaps' is to be a convenience for
actions that are already possible through a string of smaller
'qemu-img bitmap' sub-commands.  One situation not accounted for
already is that if a source image contains an inconsistent bitmap (for
example, because a qemu process died abruptly before flushing bitmap
state), the user MUST delete those inconsistent bitmaps before
anything else useful can be done with the image.

We don't want to delete inconsistent bitmaps by default: although a
corrupt bitmap is only a loss of optimization rather than a corruption
of user-visible data, it is still nice to require the user to opt in
to the fact that they are aware of the loss of the bitmap.  Still,
requiring the user to check 'qemu-img info' to see whether bitmaps are
consistent, then use 'qemu-img bitmap --remove' to remove offenders,
all before using 'qemu-img convert', is a lot more work than just
adding a knob 'qemu-img convert --bitmaps --skip-broken-bitmaps' which
opts in to skipping the broken bitmaps.

After testing the new option, also demonstrate the way to manually fix
things (either deleting bad bitmaps, or re-creating them as empty) so
that it is possible to convert without the option.

Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1946084
Signed-off-by: Eric Blake <eblake@redhat.com>
Message-Id: <20210709153951.2801666-4-eblake@redhat.com>
[eblake: warning message tweak, test enhancements]
Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
2021-07-21 14:14:41 -05:00
..
fuse-allow-other iotests/fuse-allow-other: Test allow-other 2021-07-09 12:26:05 +02:00
fuse-allow-other.out iotests/fuse-allow-other: Test allow-other 2021-07-09 12:26:05 +02:00
migrate-bitmaps-postcopy-test migrate-bitmaps-postcopy-test: check that we can't remove in-flight bitmaps 2021-03-24 13:41:19 +00:00
migrate-bitmaps-postcopy-test.out
migrate-bitmaps-test
migrate-bitmaps-test.out
mirror-top-perms iotests: Test mirror-top filter permissions 2021-04-09 18:00:29 +02:00
mirror-top-perms.out iotests: Test mirror-top filter permissions 2021-04-09 18:00:29 +02:00
nbd-qemu-allocation iotests: Improve and rename test 309 to nbd-qemu-allocation 2021-07-12 10:56:41 -05:00
nbd-qemu-allocation.out qemu-img: Make unallocated part of backing chain obvious in map 2021-07-12 11:10:53 -05:00
parallels-read-bitmap
parallels-read-bitmap.out
qemu-img-bitmaps qemu-img: Add --skip-broken-bitmaps for 'convert --bitmaps' 2021-07-21 14:14:41 -05:00
qemu-img-bitmaps.out qemu-img: Add --skip-broken-bitmaps for 'convert --bitmaps' 2021-07-21 14:14:41 -05:00
qsd-jobs iotests/qsd-jobs: Filter events in the first test 2021-04-09 18:00:29 +02:00
qsd-jobs.out block: improve permission conflict error message 2021-06-02 14:23:20 +02:00
remove-bitmap-from-backing block: Make blockdev-reopen stable API 2021-07-09 13:19:11 +02:00
remove-bitmap-from-backing.out iotests: add test for removing persistent bitmap from backing file 2021-04-09 18:00:29 +02:00