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] [xen-unstable] xm migrate: Better error report when atte

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] xm migrate: Better error report when attempt to migrate non-running domain.
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Tue, 20 May 2008 04:10:11 -0700
Delivery-date: Tue, 20 May 2008 04:10:15 -0700
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 Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1211272982 -3600
# Node ID 7c8e2a2c006ef5953ef9c50e1b5918c342ac8890
# Parent  13dda75739f2ac18a4b33bc32432f0add9450557
xm migrate: Better error report when attempt to migrate non-running domain.
Signed-off-by: Masaki Kanno <kanno.masaki@xxxxxxxxxxxxxx>
---
 tools/python/xen/xend/XendDomain.py |    4 ++++
 1 files changed, 4 insertions(+)

diff -r 13dda75739f2 -r 7c8e2a2c006e tools/python/xen/xend/XendDomain.py
--- a/tools/python/xen/xend/XendDomain.py       Tue May 20 09:41:52 2008 +0100
+++ b/tools/python/xen/xend/XendDomain.py       Tue May 20 09:43:02 2008 +0100
@@ -1282,6 +1282,10 @@ class XendDomain:
 
         if dominfo.getDomid() == DOM0_ID:
             raise XendError("Cannot migrate privileged domain %s" % domid)
+        if dominfo._stateGet() != DOM_STATE_RUNNING:
+            raise VMBadState("Domain is not running",
+                             POWER_STATE_NAMES[DOM_STATE_RUNNING],
+                             POWER_STATE_NAMES[dominfo._stateGet()])
 
         """ The following call may raise a XendError exception """
         dominfo.testMigrateDevices(True, dst)

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

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] xm migrate: Better error report when attempt to migrate non-running domain., Xen patchbot-unstable <=