Skip to contentSkip to conversation

libxl: use qemu-xen with PV guests by default

PATCH In review Stefano Stabellini 3 participants 7 messages Mar 23, 2012 – Apr 18, 2012

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 libxl: use qemu-xen with PV guests by default

qemu-xen offers better disk performances than qemu-xen-traditional because it supports Linux native AIO.

---
 tools/libxl/libxl_create.c |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)
tools/libxl/libxl_create.c +8 -3
index 8417661..dbff02c 100644
@@ -71,9 +71,14 @@ int libxl__domain_build_info_setdefault(libxl__gc *gc,
         b_info->type != LIBXL_DOMAIN_TYPE_PV)
         return ERROR_INVAL;
 
-    if (!b_info->device_model_version)
-        b_info->device_model_version =
-            LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN_TRADITIONAL;
+    if (!b_info->device_model_version) {
+        if (b_info->type == LIBXL_DOMAIN_TYPE_HVM)
+            b_info->device_model_version =
+                LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN_TRADITIONAL;
+        else
+            b_info->device_model_version =
+                LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN;
+    }
 
     if (b_info->type == LIBXL_DOMAIN_TYPE_HVM) {
         if (!b_info->u.hvm.bios)
Signature · 1 line
1.7.2.5
#1 lore raw
Quoted 2 lines · Stefano Stabellini

qemu-xen offers better disk performances than qemu-xen-traditional because it supports Linux native AIO.

The qemu-upstream test flights are failing far more often than not. In fact I expect the *single* pass (actually a "tolerable fail") we've ever had was actually a fluke. Is qemu-xen really ready to be used in this way?

Ian.

Quoted 27 lines
---
 tools/libxl/libxl_create.c |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)
tools/libxl/libxl_create.c +8 -3
index 8417661..dbff02c 100644
@@ -71,9 +71,14 @@ int libxl__domain_build_info_setdefault(libxl__gc *gc,
         b_info->type != LIBXL_DOMAIN_TYPE_PV)
         return ERROR_INVAL;
 
-    if (!b_info->device_model_version)
-        b_info->device_model_version =
-            LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN_TRADITIONAL;
+    if (!b_info->device_model_version) {
+        if (b_info->type == LIBXL_DOMAIN_TYPE_HVM)
+            b_info->device_model_version =
+                LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN_TRADITIONAL;
+        else
+            b_info->device_model_version =
+                LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN;
+    }
 
     if (b_info->type == LIBXL_DOMAIN_TYPE_HVM) {
         if (!b_info->u.hvm.bios)
#2 lore raw
Quoted 8 lines · Ian Campbell
Quoted 2 lines · Stefano Stabellini

qemu-xen offers better disk performances than qemu-xen-traditional because it supports Linux native AIO.

The qemu-upstream test flights are failing far more often than not. In fact I expect the *single* pass (actually a "tolerable fail") we've ever had was actually a fluke. Is qemu-xen really ready to be used in this way?

Actually from the test reports it looks like that's only true for HVM guests (especially Windows). This change only affects PV guests.

#3 lore raw
In reply to Stefano Stabellini

Stefano Stabellini writes ("[Xen-devel] [PATCH] libxl: use qemu-xen with PV guests by default"):

Quoted 2 lines

qemu-xen offers better disk performances than qemu-xen-traditional because it supports Linux native AIO.

Does this take any account of whether the new qemu-xen dm is installed ?

Ian.

#4 lore raw
Quoted 6 lines · Ian Jackson

Stefano Stabellini writes ("[Xen-devel] [PATCH] libxl: use qemu-xen with PV guests by default"):

Quoted 2 lines

qemu-xen offers better disk performances than qemu-xen-traditional because it supports Linux native AIO.

Does this take any account of whether the new qemu-xen dm is installed ?

I don't think it is possible to install xen-unstable without qemu-upstream-xen getting built and installed? At least not building from source, perhaps a distro might package them separately but there really ought to be a depends relationship in that case? Would we want to support a Xen without qemu-upstream-xen configuration?

Ian.

#5 lore raw
Quoted 5 lines · Ian Campbell
Quoted 4 lines · Ian Jackson

Stefano Stabellini writes ("[Xen-devel] [PATCH] libxl: use qemu-xen with PV guests by default"):

Quoted 2 lines

qemu-xen offers better disk performances than qemu-xen-traditional because it supports Linux native AIO.

Quoted 7 lines
Quoted 2 lines

Does this take any account of whether the new qemu-xen dm is installed ?

I don't think it is possible to install xen-unstable without qemu-upstream-xen getting built and installed? At least not building from source, perhaps a distro might package them separately but there really ought to be a depends relationship in that case?

I would think so.

Quoted 2 lines

Would we want to
support a Xen without qemu-upstream-xen configuration?

What if we check for the existence of the file in libxl?

If this is not acceptable I vote for assuming that qemu-xen is installed in the system.

#6 lore raw
Quoted 16 lines · Stefano Stabellini
Quoted 5 lines · Ian Campbell
Quoted 4 lines · Ian Jackson

Stefano Stabellini writes ("[Xen-devel] [PATCH] libxl: use qemu-xen with PV guests by default"):

Quoted 2 lines

qemu-xen offers better disk performances than qemu-xen-traditional because it supports Linux native AIO.

Quoted 7 lines
Quoted 2 lines

Does this take any account of whether the new qemu-xen dm is installed ?

I don't think it is possible to install xen-unstable without qemu-upstream-xen getting built and installed? At least not building from source, perhaps a distro might package them separately but there really ought to be a depends relationship in that case?

I would think so.

Quoted 7 lines
Quoted 2 lines

Would we want to
support a Xen without qemu-upstream-xen configuration?

What if we check for the existence of the file in libxl?

If this is not acceptable I vote for assuming that qemu-xen is installed in the system.

I think an access(R_X) check or whatever + log and ERROR_INVAL would be find.

Ian.