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

[Xen-changelog] [xen master] libxl: correctly parse storage devices on driver domains



commit 846bd69104e5d62f29b7282419827e52e99f3efd
Author:     Roger Pau Monne <roger.pau@xxxxxxxxxx>
AuthorDate: Fri May 3 13:23:01 2013 +0200
Commit:     Ian Campbell <ian.campbell@xxxxxxxxxx>
CommitDate: Wed May 8 12:06:41 2013 +0100

    libxl: correctly parse storage devices on driver domains
    
    Don't try to check physical devices if they belong to a domain
    different than the one where the toolstack is running. This prevents
    the following error when trying to use storage driver domains:
    
    libxl: debug: libxl_create.c:1246:do_domain_create: ao 0x1819240: create: 
how=(nil) callback=(nil) poller=0x1818fa0
    libxl: debug: libxl_device.c:235:libxl__device_disk_set_backend: Disk 
vdev=xvda spec.backend=phy
    libxl: debug: libxl_device.c:175:disk_try_backend: Disk vdev=xvda, backend 
phy unsuitable as phys path not a block device
    libxl: error: libxl_device.c:278:libxl__device_disk_set_backend: no 
suitable backend for disk xvda
    
    Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
    Acked-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
 tools/libxl/libxl_device.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/tools/libxl/libxl_device.c b/tools/libxl/libxl_device.c
index a5cf446..b1fc4ef 100644
--- a/tools/libxl/libxl_device.c
+++ b/tools/libxl/libxl_device.c
@@ -161,6 +161,12 @@ static int disk_try_backend(disk_try_backend_args *a,
             goto bad_format;
         }
 
+        if (a->disk->backend_domid != LIBXL_TOOLSTACK_DOMID) {
+            LOG(DEBUG, "Disk vdev=%s, is using a storage driver domain, "
+                       "skipping physical device check", a->disk->vdev);
+            return backend;
+        }
+
         if (a->disk->script) {
             LOG(DEBUG, "Disk vdev=%s, uses script=... assuming phy backend",
                 a->disk->vdev);
--
generated by git-patchbot for /home/xen/git/xen.git#master

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

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.