qemu/tests/qemu-iotests/260.out
Vladimir Sementsov-Ogievskiy 5d9388d4b2 iotests: add test 260 to check bitmap life after snapshot + commit
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Message-id: 20190927122355.7344-8-vsementsov@virtuozzo.com
[Maintainer edit: removed 260 from auto group per Peter Maydell. --js]
Signed-off-by: John Snow <jsnow@redhat.com>
2019-10-17 17:02:32 -04:00

52 lines
3.1 KiB
Text

Testcase non-persistent without restart
{"execute": "block-dirty-bitmap-add", "arguments": {"name": "bitmap0", "node": "drive0", "persistent": false}}
{"return": {}}
initial bitmap: name=bitmap0 dirty-clusters=1
{"execute": "blockdev-snapshot-sync", "arguments": {"device": "drive0", "format": "qcow2", "snapshot-file": "TEST_DIR/PID-top"}}
{"return": {}}
check that no bitmaps are in snapshot: not found
{"execute": "block-commit", "arguments": {"device": "drive0", "top": "TEST_DIR/PID-top"}}
{"return": {}}
{"data": {"device": "drive0", "len": 65536, "offset": 65536, "speed": 0, "type": "commit"}, "event": "BLOCK_JOB_READY", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
{"execute": "block-job-complete", "arguments": {"device": "drive0"}}
{"return": {}}
{"data": {"device": "drive0", "len": 65536, "offset": 65536, "speed": 0, "type": "commit"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
check bitmap after commit: name=bitmap0 dirty-clusters=2
check updated bitmap: name=bitmap0 dirty-clusters=3
Testcase persistent without restart
{"execute": "block-dirty-bitmap-add", "arguments": {"name": "bitmap0", "node": "drive0", "persistent": true}}
{"return": {}}
initial bitmap: name=bitmap0 dirty-clusters=1
{"execute": "blockdev-snapshot-sync", "arguments": {"device": "drive0", "format": "qcow2", "snapshot-file": "TEST_DIR/PID-top"}}
{"return": {}}
check that no bitmaps are in snapshot: not found
{"execute": "block-commit", "arguments": {"device": "drive0", "top": "TEST_DIR/PID-top"}}
{"return": {}}
{"data": {"device": "drive0", "len": 65536, "offset": 65536, "speed": 0, "type": "commit"}, "event": "BLOCK_JOB_READY", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
{"execute": "block-job-complete", "arguments": {"device": "drive0"}}
{"return": {}}
{"data": {"device": "drive0", "len": 65536, "offset": 65536, "speed": 0, "type": "commit"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
check bitmap after commit: name=bitmap0 dirty-clusters=2
check updated bitmap: name=bitmap0 dirty-clusters=3
Testcase persistent with restart
{"execute": "block-dirty-bitmap-add", "arguments": {"name": "bitmap0", "node": "drive0", "persistent": true}}
{"return": {}}
initial bitmap: name=bitmap0 dirty-clusters=1
{"execute": "blockdev-snapshot-sync", "arguments": {"device": "drive0", "format": "qcow2", "snapshot-file": "TEST_DIR/PID-top"}}
{"return": {}}
check that no bitmaps are in snapshot: not found
... Restart ...
{"execute": "block-commit", "arguments": {"device": "drive0", "top": "TEST_DIR/PID-top"}}
{"return": {}}
{"data": {"device": "drive0", "len": 65536, "offset": 65536, "speed": 0, "type": "commit"}, "event": "BLOCK_JOB_READY", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
{"execute": "block-job-complete", "arguments": {"device": "drive0"}}
{"return": {}}
{"data": {"device": "drive0", "len": 65536, "offset": 65536, "speed": 0, "type": "commit"}, "event": "BLOCK_JOB_COMPLETED", "timestamp": {"microseconds": "USECS", "seconds": "SECS"}}
check bitmap after commit: name=bitmap0 dirty-clusters=2
check updated bitmap: name=bitmap0 dirty-clusters=3