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/
Home Products Support Community News


[Xen-changelog] [xen-unstable] Fix managed domain rebooting by only comp

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] Fix managed domain rebooting by only complaining about a VM name conflict if
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Thu, 30 Nov 2006 23:00:30 +0000
Delivery-date: Thu, 30 Nov 2006 15:00:02 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
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 Ewan Mellor <ewan@xxxxxxxxxxxxx>
# Node ID fbfbc6ed47d99be3596e94a0dc3381533a8e5656
# Parent  2e529124878960e321d9dcf8c9a355805fd18ac3
Fix managed domain rebooting by only complaining about a VM name conflict if
the VM UUID conflicts as well.

Also, remove the previous_restart_time node when explicitly rebooting a guest --
the user ought to be able to drive reboots faster than the safety catch.

Signed-off-by: Ewan Mellor <ewan@xxxxxxxxxxxxx>
 tools/python/xen/xend/XendDomainInfo.py |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diff -r 2e5291248789 -r fbfbc6ed47d9 tools/python/xen/xend/XendDomainInfo.py
--- a/tools/python/xen/xend/XendDomainInfo.py   Thu Nov 30 19:11:51 2006 +0000
+++ b/tools/python/xen/xend/XendDomainInfo.py   Thu Nov 30 20:07:58 2006 +0000
@@ -479,8 +479,9 @@ class XendDomainInfo:
         if reason not in DOMAIN_SHUTDOWN_REASONS.values():
             raise XendError('Invalid reason: %s' % reason)
+        self._removeVm('xend/previous_restart_time')
         self.storeDom("control/shutdown", reason)
     def pause(self):
         """Pause domain
@@ -1692,8 +1693,9 @@ class XendDomainInfo:
             raise VmError('Invalid VM Name')
         dom =  XendDomain.instance().domain_lookup_nr(name)
-        if dom and dom != self and not dom.info['dying']:
-            raise VmError("VM name '%s' already exists" % name)
+        if dom and dom.info['uuid'] != self.info['uuid']:
+            raise VmError("VM name '%s' already exists as domain %s" %
+                          (name, str(dom.domid)))
     def update(self, info = None, refresh = True):

Xen-changelog mailing list

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] Fix managed domain rebooting by only complaining about a VM name conflict if, Xen patchbot-unstable <=