Bug 886915 - libguestfs with libvirt attach-method fails with odd error if default hypervisor is Xen
libguestfs with libvirt attach-method fails with odd error if default hypervi...
Product: Virtualization Tools
Classification: Community
Component: libguestfs (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Richard W.M. Jones
Depends On:
  Show dependency treegraph
Reported: 2012-12-13 10:15 EST by Richard W.M. Jones
Modified: 2012-12-16 15:58 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-12-16 15:58:35 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Richard W.M. Jones 2012-12-13 10:15:34 EST
Description of problem:

  unsupported flag 0x2 in function xendaemoncreatexml

The problem is that the user's default hypervisor is Xen.  libguestfs
tries to open a default libvirt connection and then create a qemu
domain, but this fails.

libguestfs should parse the libvirt capabilities to check that
qemu or kvm is actually supported, and bail with a better error
message if not.

Version-Release number of selected component (if applicable):

libguestfs 1.19.66
Comment 1 Richard W.M. Jones 2012-12-16 15:58:35 EST
I fixed libguestfs so it now parses the capabilities XML
returned by libvirt and finds the valid domain types.  If
none of the domain types are "qemu" or "kvm" then it fails
early with a useful error message:

$ export LIBGUESTFS_ATTACH_METHOD=libvirt:test:///default
$ libguestfs-test-tool
libguestfs: error: libvirt hypervisor doesn't support qemu or KVM,
so we cannot create the libguestfs appliance.
The current attach-method is:
Try setting:
  export LIBGUESTFS_ATTACH_METHOD=libvirt:qemu:///session
or if you want to have libguestfs run qemu directly, try:
or read the guestfs(3) man page

Fixed in

Note You need to log in before you can comment on or make changes to this bug.