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] If domain destruction fails because the domain does not

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] If domain destruction fails because the domain does not
From: Xen patchbot -2.0-testing <patchbot-2.0-testing@xxxxxxxxxxxxxxxxxxx>
Date: Fri, 15 Jul 2005 03:58:14 -0400
Delivery-date: Fri, 15 Jul 2005 07:58:38 +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 kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID b8347bea93247d0a15abb7000507ac3e6ef69a5f
# Parent  47dba41f4ff0b3642ca8147d19f3959386f88c50

If domain destruction fails because the domain does not
exist, that should nto be a fatal error within xend.
Just log a warning and carry on regardless. This fixes
the symptoms of a race condition during live relocation.
Signed-off-by: Keir Fraser <keir@xxxxxxxxxxxxx>

diff -r 47dba41f4ff0 -r b8347bea9324 tools/python/xen/xend/XendDomain.py
--- a/tools/python/xen/xend/XendDomain.py       Fri Jul 15 07:38:11 2005
+++ b/tools/python/xen/xend/XendDomain.py       Fri Jul 15 07:58:10 2005
@@ -560,7 +560,11 @@
 
         @param id: domain id
         """
-        dominfo = self.domain_lookup(id)
+        try:
+            dominfo = self.domain_lookup(id)
+        except:
+            log.info('Attempt to destroy non-existent domain: %s', id)
+            return 0
         log.info('Destroying domain: name=%s', dominfo.name)
         eserver.inject('xend.domain.destroy', [dominfo.name, dominfo.id])
         if dominfo:

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] If domain destruction fails because the domain does not, Xen patchbot -2 . 0-testing <=