WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] Issue diagnostic if we find dying domains on Xend restar

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] Issue diagnostic if we find dying domains on Xend restart, because we will not
From: Xen patchbot -unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 06 Oct 2005 10:16:11 +0000
Delivery-date: Thu, 06 Oct 2005 10:13:46 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User emellor@ewan
# Node ID b0bc53c9d5b6c9c5c8ff79272f7c25c7eaaf4d2a
# Parent  971e7c7411b358dec5c48fe62f55e56de9e38a94
Issue diagnostic if we find dying domains on Xend restart, because we will not
be able to show them any longer, as the paths in the store have gone.  Don't
call cleanupVm when a domain dies, as localhost-migrating VMs will be blown
away by this (there is actually a race between the saving process and the
resuming process).  This fixes bug #276.

Signed-off-by: Ewan Mellor <ewan@xxxxxxxxxxxxx>

diff -r 971e7c7411b3 -r b0bc53c9d5b6 tools/python/xen/xend/XendDomain.py
--- a/tools/python/xen/xend/XendDomain.py       Thu Oct  6 09:13:11 2005
+++ b/tools/python/xen/xend/XendDomain.py       Thu Oct  6 09:16:50 2005
@@ -146,7 +146,6 @@
         if info:
             del self.domains[domid]
             info.cleanupDomain()
-            info.cleanupVm()
 
 
     def refresh(self):
@@ -161,25 +160,31 @@
             else:
                 self._delete_domain(d.getDomid())
         for d in doms:
-            if d not in self.domains and not doms[d]['dying']:
-                try:
-                    dominfo = XendDomainInfo.recreate(doms[d])
-                    self._add_domain(dominfo)
-                except:
-                    if d == PRIV_DOMAIN:
-                        log.exception(
-                            "Failed to recreate information for domain "
-                            "%d.  Doing nothing except crossing my "
-                            "fingers.", d)
-                    else:
-                        log.exception(
-                            "Failed to recreate information for domain "
-                            "%d.  Destroying it in the hope of "
-                            "recovery.", d)
-                        try:
-                            xc.domain_destroy(dom = d)
-                        except:
-                            log.exception('Destruction of %d failed.', d)
+            if d not in self.domains:
+                if doms[d]['dying']:
+                    log.error(
+                        'Cannot recreate information for dying domain %d.  '
+                        'Xend will ignore this domain from now on.',
+                        doms[d]['dom'])
+                else:
+                    try:
+                        dominfo = XendDomainInfo.recreate(doms[d])
+                        self._add_domain(dominfo)
+                    except:
+                        if d == PRIV_DOMAIN:
+                            log.exception(
+                                "Failed to recreate information for domain "
+                                "%d.  Doing nothing except crossing my "
+                                "fingers.", d)
+                        else:
+                            log.exception(
+                                "Failed to recreate information for domain "
+                                "%d.  Destroying it in the hope of "
+                                "recovery.", d)
+                            try:
+                                xc.domain_destroy(dom = d)
+                            except:
+                                log.exception('Destruction of %d failed.', d)
 
 
     ## public:

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] Issue diagnostic if we find dying domains on Xend restart, because we will not, Xen patchbot -unstable <=