[regression] cannot use more than one vcpu

Bug #287533 reported by Jamie Strandboge
2
Affects Status Importance Assigned to Milestone
libvirt (Ubuntu)
Fix Released
High
Jamie Strandboge

Bug Description

Binary package hint: virt-manager

When using x86_64 as the architecture, and kvm as the hyperviser, I cannot use more than 1 VCPU on my dual core system. I get this error message:

Number of vcpus must be no greater than 1 for this vm type

virt-manager: 0.5.4-2ubuntu1

Related branches

description: updated
description: updated
Revision history for this message
Jamie Strandboge (jdstrand) wrote :

Problem is due to this code in qemudGetMaxVCPUs() from qemu_driver.c of libvirt:
    /* XXX future KVM will support SMP. Need to probe
       kernel to figure out KVM module version i guess */
    if (STRCASEEQ(type, "kvm"))
        return 1;

Apparently, kvm in hardy and intrepid can do vcpus up to 16. As a workaround, I hacked a small patch to /usr/share/pyshared/virtinst/util.py:

--- ./util.py.orig 2008-10-22 09:54:01.000000000 -0500
+++ util.py 2008-10-22 10:03:09.000000000 -0500
@@ -220,7 +220,11 @@
     if type is None:
         type = conn.getType()
     try:
- max = conn.getMaxVcpus(type.lower())
+ # workaround for LP: #287533
+ if type == "kvm":
+ max = 16
+ else:
+ max = conn.getMaxVcpus(type.lower())
     except libvirt.libvirtError:
         max = 32
     return max

While this is very likely not the patch we should include, it does allow my to use virt-manager and virt-install for intrepid ISO testing with multiple VCPUs.

Revision history for this message
Jamie Strandboge (jdstrand) wrote :

Strike that last patch. Per soren, we should patch libvirt.

Changed in virt-manager:
assignee: nobody → jdstrand
status: New → Triaged
Changed in libvirt:
importance: Undecided → High
Revision history for this message
Jamie Strandboge (jdstrand) wrote :

Fix committed

Changed in libvirt:
status: Triaged → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libvirt - 0.4.4-3ubuntu3

---------------
libvirt (0.4.4-3ubuntu3) intrepid; urgency=low

  * debian/patches/0008-lp287533.patch: allow 16 VCPUs when using kvm
    (LP: #287533)

 -- Jamie Strandboge <email address hidden> Wed, 22 Oct 2008 10:13:12 -0500

Changed in libvirt:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.