diff options
| author | Masanori Itoh <itoumsn@nttdata.co.jp> | 2011-04-11 23:00:53 +0900 |
|---|---|---|
| committer | Masanori Itoh <itoumsn@nttdata.co.jp> | 2011-04-11 23:00:53 +0900 |
| commit | cf3abb4ae08f594e7346eba45544c429057c83f1 (patch) | |
| tree | 66bec9d2fac92d849c6335d154ce9b1777a04f26 /nova | |
| parent | 3eb00eb2f82f0e907ecd47167510149cc853c548 (diff) | |
| parent | 25047dd2a121ea9c8e7a8ded970aa5a7254bbfc5 (diff) | |
Rebased to trunk rev 973.
Diffstat (limited to 'nova')
| -rw-r--r-- | nova/virt/libvirt_conn.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/nova/virt/libvirt_conn.py b/nova/virt/libvirt_conn.py index b949e6c92..9c665ab15 100644 --- a/nova/virt/libvirt_conn.py +++ b/nova/virt/libvirt_conn.py @@ -325,12 +325,15 @@ class LibvirtConnection(driver.ComputeDriver): state = self.get_info(instance['name'])['state'] db.instance_set_state(context.get_admin_context(), instance['id'], state) - if state == power_state.SHUTDOWN: + if state == power_state.SHUTOFF: break - except Exception: + except Exception as ex: + msg = _("Error encountered when destroying instance '%(id)s': " + "%(ex)s") % {"id": instance["id"], "ex": ex} + LOG.debug(msg) db.instance_set_state(context.get_admin_context(), instance['id'], - power_state.SHUTDOWN) + power_state.SHUTOFF) break self.firewall_driver.unfilter_instance(instance) |
