diff options
author | Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> | 2021-08-24 11:38:53 +0300 |
---|---|---|
committer | Hanna Reitz <hreitz@redhat.com> | 2021-09-01 14:38:08 +0200 |
commit | 66b63809fa71c6880f9ec4fa3d32e35c79699ae6 (patch) | |
tree | d30642072bc32a53ff4a13d6075f1416848d4d5a /tests | |
parent | b23c3b1459e423159027fb413527dc0bf60acedf (diff) |
iotests/image-fleecing: rename tgt_node
Actually target of backup(sync=None) is not a final backup target:
image fleecing is intended to be used with external tool, which will
copy data from fleecing node to some real backup target.
Also, we are going to add a test case for "push backup with fleecing",
where instead of exporting fleecing node by NBD, we'll start a backup
job from fleecing node to real backup target.
To avoid confusion, let's rename temporary fleecing node now.
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Message-Id: <20210824083856.17408-32-vsementsov@virtuozzo.com>
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/qemu-iotests/tests/image-fleecing | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/qemu-iotests/tests/image-fleecing b/tests/qemu-iotests/tests/image-fleecing index 961941bb27..ec4ef5f3f6 100755 --- a/tests/qemu-iotests/tests/image-fleecing +++ b/tests/qemu-iotests/tests/image-fleecing @@ -71,6 +71,7 @@ with iotests.FilePath('base.img') as base_img_path, \ log('') src_node = 'source' + tmp_node = 'temp' vm.add_blockdev(f'driver={iotests.imgfmt},file.driver=file,' f'file.filename={base_img_path},node-name={src_node}') vm.add_device('virtio-scsi') @@ -82,12 +83,11 @@ with iotests.FilePath('base.img') as base_img_path, \ log('--- Setting up Fleecing Graph ---') log('') - tgt_node = 'fleeceNode' - # create tgt_node backed by src_node + # create tmp_node backed by src_node log(vm.qmp('blockdev-add', { 'driver': 'qcow2', - 'node-name': tgt_node, + 'node-name': tmp_node, 'file': { 'driver': 'file', 'filename': fleece_img_path, @@ -99,19 +99,19 @@ with iotests.FilePath('base.img') as base_img_path, \ log(vm.qmp('blockdev-backup', job_id='fleecing', device=src_node, - target=tgt_node, + target=tmp_node, sync='none')) log('') log('--- Setting up NBD Export ---') log('') - nbd_uri = 'nbd+unix:///%s?socket=%s' % (tgt_node, nbd_sock_path) + nbd_uri = 'nbd+unix:///%s?socket=%s' % (tmp_node, nbd_sock_path) log(vm.qmp('nbd-server-start', {'addr': { 'type': 'unix', 'data': { 'path': nbd_sock_path } } })) - log(vm.qmp('nbd-server-add', device=tgt_node)) + log(vm.qmp('nbd-server-add', device=tmp_node)) log('') log('--- Sanity Check ---') @@ -149,7 +149,7 @@ with iotests.FilePath('base.img') as base_img_path, \ assert e is not None log(e, filters=[iotests.filter_qmp_event]) log(vm.qmp('nbd-server-stop')) - log(vm.qmp('blockdev-del', node_name=tgt_node)) + log(vm.qmp('blockdev-del', node_name=tmp_node)) vm.shutdown() log('') |