libvirt: Always disconnect_volume after rebase failures
Previously failures when rebasing onto a new volume would leave the
volume connected to the compute host. For some volume backends such as
iSCSI the subsequent call to terminate_connection would then result in
leftover devices remaining on the host.
This change simply catches any error associated with the rebase and
ensures that disconnect_volume is called for the new volume prior to
terminate_connection finally being called.
Reviewed: https:/ /review. openstack. org/458807 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=809065485c1 9fd535db6740bb2 1b867c41c008fe
Committed: https:/
Submitter: Jenkins
Branch: master
commit 809065485c19fd5 35db6740bb21b86 7c41c008fe
Author: Lee Yarwood <email address hidden>
Date: Thu Apr 20 19:43:32 2017 +0100
libvirt: Always disconnect_volume after rebase failures
Previously failures when rebasing onto a new volume would leave the connection would then result in
volume connected to the compute host. For some volume backends such as
iSCSI the subsequent call to terminate_
leftover devices remaining on the host.
This change simply catches any error associated with the rebase and connection finally being called.
ensures that disconnect_volume is called for the new volume prior to
terminate_
Change-Id: I5997000a0ba634 1c4987405cdc076 0c3b471bd59
Closes-bug: #1685185