From 0fd7949dddf2700e21ac459fb6be23d0c0e64645 Mon Sep 17 00:00:00 2001 From: micafer Date: Mon, 29 Jun 2020 13:37:53 +0200 Subject: [PATCH] Minor fix --- IM/connectors/OpenStack.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/IM/connectors/OpenStack.py b/IM/connectors/OpenStack.py index 657010a83..856a37d97 100644 --- a/IM/connectors/OpenStack.py +++ b/IM/connectors/OpenStack.py @@ -1307,6 +1307,7 @@ def finalize(self, vm, last, auth_data): # First try to detach the volumes and the SGs for vol_id in vm.volumes: try: + self.log_debug("Dettaching volume %s." % vol_id) volume = node.driver.ex_get_volume(vol_id) node.driver.detach_volume(volume) except Exception as ex: @@ -1314,10 +1315,11 @@ def finalize(self, vm, last, auth_data): try: for sg_name in self._get_security_names(vm.inf): + self.log_debug("Dettaching SG %s." % sg_name) security_group = OpenStackSecurityGroup(None, None, sg_name, "", node.driver) node.driver.ex_remove_security_group_from_node(security_group, node) except Exception as ex: - self.log_exception("Error dettaching volume %s." % vol_id) + self.log_exception("Error dettaching SG %s." % sg_name) res = node.destroy() success.append(res)