21307395 nova ZoneConfig class should call cancelConfig when editConfig fails in __exit__
authorBrian Reitz <Brian.Reitz@Oracle.COM>
Tue, 23 Jun 2015 14:51:21 -0700
changeset 4551 aeda29f57900
parent 4550 1235ed3c5285
child 4552 232fe134fd76
21307395 nova ZoneConfig class should call cancelConfig when editConfig fails in __exit__
components/openstack/nova/files/solariszones/driver.py
--- a/components/openstack/nova/files/solariszones/driver.py	Thu Jun 25 13:27:37 2015 -0700
+++ b/components/openstack/nova/files/solariszones/driver.py	Tue Jun 23 14:51:21 2015 -0700
@@ -195,6 +195,9 @@
                 LOG.error(_("Unable to commit the new configuration for "
                             "instance '%s' via zonemgr(3RAD): %s")
                           % (self.zone.name, err))
+
+                # Last ditch effort to cleanup.
+                self.zone.cancelConfig()
                 raise
 
     def setprop(self, resource, prop, value):