xen-hypervisor: GetVcpus may not find a certain domain

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



xen-hypervisor: GetVcpus may not find a certain domain

Observed on connections that have been running and then shut
down. The hypervisor subdriver fills the log with internal
errors while the xend driver actually can handle the query.

This only handles the case which I observed after shutting
down an instance via virt-manager and leaving its console
window open. The same reasoning would probably be true for
other internal errors as long as they potentially get recovered
by other sub-drivers.

BugLink: http://bugs.launchpad.net/bugs/963006

Signed-off-by: Stefan Bader <stefan.bader@xxxxxxxxxxxxx>

Index: libvirt-0.9.8/src/xen/xen_driver.c
===================================================================
--- libvirt-0.9.8.orig/src/xen/xen_driver.c	2011-12-02 04:59:50.000000000 +0100
+++ libvirt-0.9.8/src/xen/xen_driver.c	2012-03-23 11:31:53.982620050 +0100
@@ -1190,6 +1190,8 @@
             if (ret > 0)
                 return ret;
         }
+
+    xenUnifiedError(VIR_ERR_NO_SUPPORT, __FUNCTION__);
     return -1;
 }
 
Index: libvirt-0.9.8/src/xen/xen_hypervisor.c
===================================================================
--- libvirt-0.9.8.orig/src/xen/xen_hypervisor.c	2012-03-23 10:58:29.000000000 +0100
+++ libvirt-0.9.8/src/xen/xen_hypervisor.c	2012-03-23 11:26:50.741137585 +0100
@@ -3612,8 +3612,11 @@
                                &dominfo);
 
     if ((ret < 0) || (XEN_GETDOMAININFO_DOMAIN(dominfo) != domain->id)) {
-        virXenErrorFunc(VIR_ERR_INTERNAL_ERROR, __FUNCTION__,
-                        _("cannot get domain details"), 0);
+        /* This can happen if an instance is just shut down. It is probably
+         * better to leave the shouting to the unified caller.
+         * virXenErrorFunc(VIR_ERR_INTERNAL_ERROR, __FUNCTION__,
+         *                 _("cannot get domain details"), 0);
+         */
         return (-1);
     }
     nbinfo = XEN_GETDOMAININFO_CPUCOUNT(dominfo) + 1;

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]