aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkfraser@localhost.localdomain <kfraser@localhost.localdomain>2007-05-30 10:06:23 +0100
committerkfraser@localhost.localdomain <kfraser@localhost.localdomain>2007-05-30 10:06:23 +0100
commit4cd3453855a742cb67e36a86f0938f508de656f5 (patch)
tree98de1b1dbf0e963bd5126ec5cb05f28e7a90457f
parent29dd27927cb9cff9e97e1e6b6b25a425c30e238d (diff)
downloadxen-4cd3453855a742cb67e36a86f0938f508de656f5.tar.gz
xen-4cd3453855a742cb67e36a86f0938f508de656f5.tar.bz2
xen-4cd3453855a742cb67e36a86f0938f508de656f5.zip
xend: Don't destroy domains on shutdown timeout.
Do not destroy domains on shutdown timeout: the administrator needs to be able to decide what to do if a domain does not shut down. Signed-off-by: John Levon <john.levon@sun.com>
-rw-r--r--tools/python/xen/xend/XendDomainInfo.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/python/xen/xend/XendDomainInfo.py b/tools/python/xen/xend/XendDomainInfo.py
index ca780c2895..332da807bb 100644
--- a/tools/python/xen/xend/XendDomainInfo.py
+++ b/tools/python/xen/xend/XendDomainInfo.py
@@ -1128,8 +1128,8 @@ class XendDomainInfo:
# failed. Ignore this domain.
pass
else:
- # Domain is alive. If we are shutting it down, then check
- # the timeout on that, and destroy it if necessary.
+ # Domain is alive. If we are shutting it down, log a message
+ # if it seems unresponsive.
if xeninfo['paused']:
self._stateSet(DOM_STATE_PAUSED)
else:
@@ -1138,11 +1138,11 @@ class XendDomainInfo:
if self.shutdownStartTime:
timeout = (SHUTDOWN_TIMEOUT - time.time() +
self.shutdownStartTime)
- if timeout < 0:
+ if (timeout < 0 and not self.readDom('xend/unresponsive')):
log.info(
"Domain shutdown timeout expired: name=%s id=%s",
self.info['name_label'], self.domid)
- self.destroy()
+ self.storeDom('xend/unresponsive', 'True')
finally:
self.refresh_shutdown_lock.release()