Right now, on a virsh blockcopy, I know you can do something like this:

# Connect DEST target
iscsiadm -m node -p ${DESTINATION}:3260 -T ${VOLNAME} -o new
iscsiadm -m node -p ${DESTINATION}:3260 -T ${VOLNAME} --login

# Copy to connected iSCSI target
virsh blockcopy ${DOMAIN} vda /dev/sdc --raw --bandwidth 300

However I have libiscsi compiled into my QEMU. So I can do this with the monitor directly (and avoid the need to call out to external iscsiadm):

virsh qemu-monitor-command ${DOMAIN} '{"execute":"drive-mirror", "arguments": { "device": "drive-virtio-disk0", "target": "iscsi://${TARGET_IP}:3260/${DOMAIN}/1", "mode": "existing", "sync": "full", "on-source-error": "stop", "on-target-error": "stop" } }'

Is there a way to use the libiscsi compiled into my QEMU with virsh blockcopy command? I haven't been able to find any examples of using blockcopy with iSCSI compiled into QEMU.

_______________________________________________
libvirt-users mailing list
libvirt-users@redhat.com
https://www.redhat.com/mailman/listinfo/libvirt-users

Reply via email to