On 20.05.21 16:22, Vladimir Sementsov-Ogievskiy wrote:
New fleecing method becomes available: copy-before-write filter.
Actually we don't need backup job to setup image fleecing. Add test
for new recommended way of image fleecing.
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsement...@virtuozzo.com>
---
tests/qemu-iotests/tests/image-fleecing | 50 +++++++++-----
tests/qemu-iotests/tests/image-fleecing.out | 72 +++++++++++++++++++++
2 files changed, 107 insertions(+), 15 deletions(-)
diff --git a/tests/qemu-iotests/tests/image-fleecing
b/tests/qemu-iotests/tests/image-fleecing
index e210c00d28..404ebc00f1 100755
--- a/tests/qemu-iotests/tests/image-fleecing
+++ b/tests/qemu-iotests/tests/image-fleecing
[...]
@@ -90,12 +91,22 @@ def do_test(base_img_path, fleece_img_path, nbd_sock_path,
vm):
'backing': src_node,
}))
- # Establish COW from source to fleecing node
- log(vm.qmp('blockdev-backup',
- job_id='fleecing',
- device=src_node,
- target=tmp_node,
- sync='none'))
+ # Establish CBW from source to fleecing node
+ if use_cbw:
+ log(vm.qmp('blockdev-add', **{
I thought this should work without ** now.
With them dropped:
Reviewed-by: Max Reitz <mre...@redhat.com>
+ 'driver': 'copy-before-write',
+ 'node-name': 'fl-cbw',
+ 'file': src_node,
+ 'target': tmp_node
+ }))
+
+ log(vm.qmp('qom-set', path=qom_path, property='drive', value='fl-cbw'))
+ else:
+ log(vm.qmp('blockdev-backup',
+ job_id='fleecing',
+ device=src_node,
+ target=tmp_node,
+ sync='none'))
log('')
log('--- Setting up NBD Export ---')