I was playing around with using KVM because I have used Xen and I was wondering about KVM. I have headless servers which I use to play around with this stuff and they don't have X installed on them. So I tried the standard method and that doesn't work because KVM automatically assumes that it should run SDL. The alternative is to run VNC. The version of KVM that ships with Gutsy is broken and does not properly handle VNC, therefore you have to get the latest from the repository and compile it yourself. Afterwards run the system.
I am leaving out all the steps for howto affectionados:
Remove the existing files:
apt-get remove kvm qemu
apt-get autoremove -y
Install headers, build-essential, lidbsd, and gcc 3.4:
apt-get install -y linux-headers-`uname -r` build-essential libsdl1.2-dev gcc-3.4
Now go grab the latest tar.gz from the kvm project on sourceforge.
./configure --prefix=/usr
make
make install
The installed version the "kvm" command is called qemu-system-x86_64 or something as such depending on your architecture the -x86_64 part might differ, you can create a link from kvm to qemu... if you're so inclined.
Run the vm with something like, the whole system runs as if it were an application under the host OS:
qemu-system-x86_64 -m 256 -cdrom /path/ubuntu-7.10-server-amd64.iso -std-vga -vnc 192.168.12.11:0 -boot d gutsy.img
192.168.12.11 should be an IP assigned to the host machine.
Connect to the IP, i.e. 192.168.12.11, via a vnc client and you should see the install dialog for ubuntu.