Bug 724814 - qemu -device ? fails, breaks libvirt capabilities reporting (and thus virt-manager vm creation)
Summary: qemu -device ? fails, breaks libvirt capabilities reporting (and thus virt-ma...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: qemu
Version: 16
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Justin M. Forbes
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: AcceptedBlocker
Depends On:
Blocks: F16Beta, F16BetaBlocker 726066
TreeView+ depends on / blocked
 
Reported: 2011-07-21 21:20 UTC by Cole Robinson
Modified: 2018-04-11 13:18 UTC (History)
18 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-09-06 18:43:05 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Fix default accelerator for non-KVM builds (400 bytes, patch)
2011-08-04 14:06 UTC, Daniel Berrangé
no flags Details | Diff

Description Cole Robinson 2011-07-21 21:20:11 UTC
On f14:

$ qemu -device ?
Could not initialize KVM, will disable KVM support
name "virtio-balloon-pci", bus PCI
name "virtio-serial-pci", bus PCI, alias "virtio-serial"
...

On rawhide (from inside a VM so lack of hardware virt may be the cause):

$ qemu -device ?
No accelerator found!
KVM not supported for this target

According the Rich Jones, this is specific to fedora's qemu package:

http://lists.gnu.org/archive/html/qemu-devel/2011-07/msg01776.html

Comment 1 Richard W.M. Jones 2011-07-21 21:42:10 UTC
Actually the solution (for me) was simply to update seabios-bin
to the latest version.  ie. There's a missing Requires.

There is another issue though.  In Koji, where only TCG is
available, it appears you have to add the -machine accel=tcg
option, otherwise qemu -device \? fails.

Comment 2 Richard W.M. Jones 2011-07-21 21:43:15 UTC
(In reply to comment #1)
> option, otherwise qemu -device \? fails.

(I should make this clear)  The command fails in Koji even
if seabios-bin is at the latest version.

Comment 3 Adam Williamson 2011-08-04 01:07:55 UTC
I'm seeing this (or something similar) in current F16, referred to this bug by dallen.

Running virt-manager shows no machines on the localhost (although there is one). If I click New, the dialog has an error message "Error: No hypervisor options were found for this connection". This prevents me creating a new VM.

The system is correctly configured - modules are loaded, VT-D is not disabled in the BIOS, there's no messages about kvm in /var/log/messages . Running VMs worked a couple of weeks back, and I have not changed the configuration since.

I'm not sure about the seabios thing - I have the latest seabios F16 package, and I just tried building upstream git master and replacing /usr/share/seabios/bios.bin with the built copy, and it didn't seem to change anything.

Proposing as an F16 Beta blocker.

Comment 4 Richard W.M. Jones 2011-08-04 07:30:59 UTC
Installing seabios-bin was necessary to fix a different bug
in qemu.  The main bug (that qemu -device ? fails and breaks
everything) is still present even with seabios-bin installed.

I agree this is a F16 blocker bug, since it literally breaks
every part of libvirt and virtualization in Fedora.

Comment 5 Daniel Berrangé 2011-08-04 14:06:43 UTC
Created attachment 516717 [details]
Fix default accelerator for non-KVM builds

Comment 6 Daniel Berrangé 2011-08-04 14:23:25 UTC
Posted upstream too

http://article.gmane.org/gmane.comp.emulators.kvm.devel/77313

Comment 7 Matěj Cepl 2011-08-04 20:21:11 UTC
Seems like this build http://koji.fedoraproject.org/koji/buildinfo?buildID=257220 (scratch build for F16 is http://koji.fedoraproject.org/koji/taskinfo?taskID=3252725 ) actually fixes the problem. At least virsh list --all shows my machines.

Comment 8 Adam Williamson 2011-08-05 00:01:26 UTC
I can confirm that build lets me create a VM. I hit an error trying to boot it, though:

------------------------

Unable to complete install: 'internal error Process exited while reading console log output: char device redirected to /dev/pts/3
do_spice_init: starting 0.9.0
spice_server_add_interface: SPICE_INTERFACE_KEYBOARD
spice_server_add_interface: SPICE_INTERFACE_MOUSE
qemu-kvm: /builddir/build/BUILD/qemu-kvm-0.15.0/hw/vhost.c:123: vhost_dev_unassign_memory: Assertion `to >= 0' failed.
'

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/asyncjob.py", line 44, in cb_wrapper
    callback(asyncjob, *args, **kwargs)
  File "/usr/share/virt-manager/virtManager/create.py", line 1899, in do_install
    guest.start_install(False, meter=meter)
  File "/usr/lib/python2.7/site-packages/virtinst/Guest.py", line 1223, in start_install
    noboot)
  File "/usr/lib/python2.7/site-packages/virtinst/Guest.py", line 1291, in _create_guest
    dom = self.conn.createLinux(start_xml or final_xml, 0)
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 1836, in createLinux
    if ret is None:raise libvirtError('virDomainCreateLinux() failed', conn=self)
libvirtError: internal error Process exited while reading console log output: char device redirected to /dev/pts/3
do_spice_init: starting 0.9.0
spice_server_add_interface: SPICE_INTERFACE_KEYBOARD
spice_server_add_interface: SPICE_INTERFACE_MOUSE
qemu-kvm: /builddir/build/BUILD/qemu-kvm-0.15.0/hw/vhost.c:123: vhost_dev_unassign_memory: Assertion `to >= 0' failed.

--------------------

Probably should file that separately.

Comment 9 Adam Williamson 2011-08-05 00:02:14 UTC
Justin, you'll need to submit the updated qemu as an update via Bodhi to get this into the Alpha. bonus points if you fix the subsequent bug ;) thanks!

Comment 10 Justin M. Forbes 2011-08-23 15:04:29 UTC
Sorry, things were moving rather quickly as we got the 0.15.0 final release out.  0.15.0-3 has been submitted to bodhi and should take care of this issue.

Comment 11 Tim Flink 2011-09-01 17:43:36 UTC
Discussed in the 2011-08-26 blocker review meeting. Accepted as a Fedora 16 beta blocker as it violates the following beta release criterion [1]:

The release must boot successfully as a virtual guest in a situation where the virtual host is running the same release (using Fedora's current preferred virtualization technology)

[1] https://fedoraproject.org/wiki/Fedora_16_Beta_Release_Criteria

Comment 12 Adam Williamson 2011-09-06 18:43:05 UTC
https://admin.fedoraproject.org/updates/qemu-0.15.0-3.fc16 went stable on 08-30, so let's close this.


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