From: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
To: qemu-devel@nongnu.org, qemu-block@nongnu.org
Cc: kwolf@redhat.com, mreitz@redhat.com
Subject: [Qemu-devel] [PATCH] iotests: fix 254 for qcow (1)
Date: Wed, 5 Jun 2019 18:26:50 +0300 [thread overview]
Message-ID: <20190605152650.103483-1-vsementsov@virtuozzo.com> (raw)
Qcow default cluster size is 4k, but default format of created overlay
image on snapshot operation is qcow2 with it's default cluster of 64k.
This leads to block-dirty-bitmap-merge fail when test run for qcow
format, as it can't merge bitmaps with different granularities.
Let's fix it by specifying strict granularity.
Reported-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
---
tests/qemu-iotests/254 | 5 +++--
tests/qemu-iotests/254.out | 3 ++-
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/tests/qemu-iotests/254 b/tests/qemu-iotests/254
index 33cb80a512..a8ea5818ff 100755
--- a/tests/qemu-iotests/254
+++ b/tests/qemu-iotests/254
@@ -29,7 +29,8 @@ qemu_img_create('-f', iotests.imgfmt, disk, str(size))
vm = iotests.VM().add_drive(disk, opts='node-name=base')
vm.launch()
-vm.qmp_log('block-dirty-bitmap-add', node='drive0', name='bitmap0')
+vm.qmp_log('block-dirty-bitmap-add', node='drive0', name='bitmap0',
+ granularity=65536)
vm.hmp_qemu_io('drive0', 'write 0 512K')
@@ -38,7 +39,7 @@ vm.qmp_log('transaction', indent=2, actions=[
'data': {'device': 'drive0', 'snapshot-file': top,
'snapshot-node-name': 'snap'}},
{'type': 'block-dirty-bitmap-add',
- 'data': {'node': 'snap', 'name': 'bitmap0'}},
+ 'data': {'node': 'snap', 'name': 'bitmap0', 'granularity': 65536}},
{'type': 'block-dirty-bitmap-merge',
'data': {'node': 'snap', 'target': 'bitmap0',
'bitmaps': [{'node': 'base', 'name': 'bitmap0'}]}}
diff --git a/tests/qemu-iotests/254.out b/tests/qemu-iotests/254.out
index d7394cf002..dc899016da 100644
--- a/tests/qemu-iotests/254.out
+++ b/tests/qemu-iotests/254.out
@@ -1,4 +1,4 @@
-{"execute": "block-dirty-bitmap-add", "arguments": {"name": "bitmap0", "node": "drive0"}}
+{"execute": "block-dirty-bitmap-add", "arguments": {"granularity": 65536, "name": "bitmap0", "node": "drive0"}}
{"return": {}}
{
"execute": "transaction",
@@ -14,6 +14,7 @@
},
{
"data": {
+ "granularity": 65536,
"name": "bitmap0",
"node": "snap"
},
--
2.18.0
next reply other threads:[~2019-06-05 15:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-06-05 15:26 Vladimir Sementsov-Ogievskiy [this message]
2019-06-05 15:33 ` [Qemu-devel] [PATCH] iotests: fix 254 for qcow (1) Max Reitz
2019-06-05 15:47 ` Vladimir Sementsov-Ogievskiy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190605152650.103483-1-vsementsov@virtuozzo.com \
--to=vsementsov@virtuozzo.com \
--cc=kwolf@redhat.com \
--cc=mreitz@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).