Ubuntu

libvirt expexts qemu-dm in wrong path for xen

Reported by Stefan Bader on 2012-01-11
20
This bug affects 2 people
Affects Status Importance Assigned to Milestone
libvirt (Ubuntu)
High
Serge Hallyn
Oneiric
High
Unassigned
Precise
High
Unassigned
Quantal
High
Serge Hallyn

Bug Description

Host Release: Oneiric, PRecise
Host Architecture: amd64

When trying to create a new instance with the Xen hypervisor running either Oneiric or Precise, setup fails because the python scripts on the host expect qemu-dm to be located under /usr/lib64/xen (I believe the 32bit path would be wrong as well but we do not support the Xen host to be 32bit) but the correct path is /usr/lib/xen-4.1

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libvirt - 0.9.8-2ubuntu2

---------------
libvirt (0.9.8-2ubuntu2) precise; urgency=low

  * debian/patches/fix-ubuntu-xen-qemu-dm-path.patch:
    Fix qemu-dm paths so Xen can be used with libvirt.
    (LP: #914788)
 -- Chuck Short <email address hidden> Wed, 18 Jan 2012 14:31:27 -0500

Changed in libvirt (Ubuntu):
status: New → Fix Released
Stefan Bader (smb) wrote :

Could we backport this to Oneric?

Stefan Bader (smb) wrote :

Verified paths being correct after upgrading to the 0.9.8-2ubuntu4 version of the package.

Sridutt (sriduttvnayak) wrote :

When I download and run ./configure in this, I am getting an error:

checking for LIBXML... no checking libxml2 xml2-config >= 2.6.0 ... configure: error: Could not find libxml2 anywhere (see config.log for details).

Any solutions?

Serge Hallyn (serge-hallyn) wrote :

@Sridutt,

You probably need to

sudo apt-get install libxml2-dev libxml2-utils

GeorgeDunlap (dunlapg) wrote :

It looks like this bug is back in some form for the 12.10 beta:

virt-install -n vi-test -r 512 --disk path=/vm/vi-test.img,size=4 -c /vm/iso/ubuntu-12.10-beta1-server-amd64.iso --network network=default --connect=xen:/// --vnc --noautoconsole -v

Starting install...
Creating storage file vi-test.img | 4.0 GB 00:00
ERROR POST operation failed: xend_post: error from xen daemon: (xend.err "Error creating domain: device model '/usr/lib/xen-default/bin/qemu-dm' not found")
Domain installation does not appear to have been successful.
If it was, you can restart your domain by running:
  virsh --connect xen:/// start vi-test
otherwise, please restart your installation.

GeorgeDunlap (dunlapg) wrote :

It looks like the patch mentioned above changes the path *to* "/usr/lib/xen-default/...". According to this debian bug conversation, the right solution is to just use "qemu-dm", and allow the toolstack to figure out the path to the binary:

http://us.generation-nt.com/answer/bug-685749-xen-utils-4-1-usr-lib-xen-default-missing-help-208638802.html

I'm downloading libvirt:quantal-proposed now; I'll see if I can get a patch that implements that fix.

GeorgeDunlap (dunlapg) wrote :

The attached file is a replacement for the "fix-ubuntu-xen-qemu-dm-path.patch". It does two things:
* Removes all absolute paths for qemu-dm and hvmloader, making them just "qemu-dm" and "hvmloader" respectively
* Changes the xml template for the "emulate" and "bootloader" fields to be "filePath" rather than "absFilePath", to allow the checks above to succeed.

I've built libvirt/quantal-proposed with this change, and successfully make an HVM guest using the resulting libvirt.

Stefan Bader (smb) wrote :

I looked at the changes George proposed and they looked ok. I prepared a branch with those and another patch I wanted to get re-freshed+activated for quite some time. Maybe we can get those reviewed and uploaded before the next security upload renders the branch less useful. ;)

Stefan Bader (smb) wrote :

Oh, forgot to mention. I also did a test-build and verified that with the new libvirt in Quantal I still can create a new guest (in the xend persistent configuration paths become absolute again).

Stefan Bader (smb) on 2012-10-05
Changed in libvirt (Ubuntu):
status: Fix Released → Triaged
Changed in libvirt (Ubuntu Precise):
status: New → Fix Released
Changed in libvirt (Ubuntu Oneiric):
importance: Undecided → High
Changed in libvirt (Ubuntu Precise):
importance: Undecided → High
Changed in libvirt (Ubuntu Quantal):
importance: Undecided → High
Changed in libvirt (Ubuntu Oneiric):
status: New → Confirmed
Changed in libvirt (Ubuntu Quantal):
milestone: none → ubuntu-12.10
Stefan Bader (smb) wrote :

Cannot remember but either it was not a problem or nobody really depends on it. So as long as there isn't someone really in need I would not touch Oneiric.

Changed in libvirt (Ubuntu Oneiric):
status: Confirmed → Won't Fix
Stefan Bader (smb) wrote :

The Xen version in Precise is ok with the current patch, so that can remain "Fix released" (as long as Xen-4.1.3 is not backported to Precise).

Changed in libvirt (Ubuntu Quantal):
assignee: nobody → Serge Hallyn (serge-hallyn)

The attachment "Updated patch for quantal." of this bug report has been identified as being a patch. The ubuntu-reviewers team has been subscribed to the bug report so that they can review the patch. In the event that this is in fact not a patch you can resolve this situation by removing the tag 'patch' from the bug report and editing the attachment so that it is not flagged as a patch. Additionally, if you are member of the ubuntu-reviewers team please also unsubscribe the team from this bug report.

[This is an automated message performed by a Launchpad user owned by Brian Murray. Please contact him regarding any issues with the action taken in this bug report.]

tags: added: patch
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libvirt - 0.9.13-0ubuntu12

---------------
libvirt (0.9.13-0ubuntu12) quantal; urgency=low

  * Refresh fix-ubuntu-xen-qemu-dm-path.patch to only use executable
    names and let the toolchain find out the right paths (LP: #914788).
    Thanks George Dunlap.
  * Refresh and re-activate xen_hypervisor-treat-missing-privcmd-file-
    as-temporary.patch (LP: #922486)
 -- Stefan Bader <email address hidden> Fri, 05 Oct 2012 11:35:43 +0200

Changed in libvirt (Ubuntu Quantal):
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers