Re: KVM usability

Dustin Kirkland
2010-03-01T21:12:34Z

On Sat, Feb 27, 2010 at 4:56 AM, Ingo Molnar <mingo@elte.hu> wrote:
> Here's my experience with it:
>
>  - qemu-kvm starts up with a miniature resolution by default. 640x480 - on my
>   1680x1050 laptop screen. It's so small that initially i even overlooked
>   that i started it. It should multiplex pixels up to a reasonable screen
>   size by default.
>
>  - The mouse is trapped straight away by default if you click into it. That's
>   very annoying if you actually try to integrate a guest OS into your desktop
>   - it's not just 'another, slightly weird app' but a sticky, opinionated GUI
>   component that you have to fight with all the time.
>
>  - Once trapped it's not obvious how to untrap the mouse. The qemu window
>   title says:
>
>          QEMU: Press Ctrl-ALT to exit grab
>
>   Of course once you _know_ what a 'grab' is, you'll know where to look.
>   At minimum it should say:
>
>          QEMU: Press Ctrl-ALT to exit mouse grab
>
>   But to first-time users it's an annoying trap of the mouse and with no
>   obvious place to look for help. [besides, it doesnt tell which Ctrl and
>   which ALT to use - it's the left side. The right side Ctrl does not work.]
>
>  - Graphics performance is awful even with the 640x480 miniature version.
>   During bootup I can see it drawing single characters. This is a Core2
>   2.8GHz.
>
>  - Sound does not work by default. I have to go dig into command-line options
>   to see that i need to add: "-soundhw all". Why isnt sound enabled by
>   default?

..snip..

> ( I could go on and on about finer details of good integration, like the
>  difficulty of integrating host/guest files, networking, no way to quickly
>  attach ISOs via that window, no way to activate networking, sound and no way
>  to snapshot, no way to increase memory size except a command line option. )

...snip...

> I'm not trolling you at all: is it _really_ not obvious to you that the
> KVM/qemu usability status quo honestly sucks, to an unbiased observer?

Hi there-

To a few of your comments shown above...I've noticed these two, and
they've bothered me a bit.

As Jan (and others) have mentioned, these are often "addressed" by
frontends running on top of kvm (and libvirt). I look at kvm as a
swissarmy knife, with lots of buttons and knobs and whistles, but you
have to give it all of the "right" options to get it to do what you
want.

The graphical frontends make this easier. But running KVM from the
command line, with the bare minimal options, is often a functional,
but non-satisfactory impression of KVM.

Maintaining the qemu-kvm package in Ubuntu, I've seen this over and
over and over again, with Ubuntu users expecting a much smoother
graphical experience. "Why can't I get my mouse back?" "Why doesn't
sound work?" "How do I make networking work?" "Why is the resolution
so low?" Etc.

For these reasons (among others), we've created a little package and a
python script in Ubuntu called Testdrive [1], which basically
downloads an ISO (using rsync/zsync against cached images, if
possible), and launches a VM
with a "healthy" set of options. The package puts a pointy/clicky
option in the Applications menu, and makes for a *very* easy way for
Ubuntu users to launch a VM and try out the daily ISO builds (as well
as install to the backing disk image).

Once it's running, the kvm process looks something like this:

kvm -m 512 -cdrom
/home/kirkland/.cache/testdrive/iso/lucid-desktop-amd64.iso -drive
file=/home/kirkland/.cache/testdrive/img/testdrive-disk-0086OD.img,if=virtio,index=0,boot=on
-usb -usbdevice tablet -net nic,model=virtio -net user -soundhw es1370

Among these:
* 512MB is a nice step up from the 128MB by default (this one scales
based on your hosts memory)
* virtio is used for disk and network for nice performance gains
* usb device tablet greatly improves the mouse experience
* sound card added
* qcow2 sparse disk image
* desktop is 1024 x 720

For what it's worth, you can just as easily run:
testdrive -u http://download.fedoraproject.org/pub/fedora/linux/releases/12/Live/i686/Fedora-12-i686-Live.iso
or any other http://, ftp://, rsync://, or file:/// accessible ISO.

By no means is Testdrive supposed to be a production quality frontend
for KVM (or replace any of the libvirt-based utilities like
virt-manager). But I think it shows that KVM's default set of options
is a little shy of what people expect for Desktop virtualization at
least. For servers, lightweight defaults are perhaps more acceptable?
But KVM has a number of new users by way of Ubuntu users just
pointing and clicking "Testdrive" and launching a VM.

[1] http://launchpad.net/testdrive

Cheers,
:-Dustin