If you’re running Fedora 12, getting started with SPICE is super easy. In this post I’ll demonstrate getting the most basic implementation working with Red Hat’s spice client that was released two days ago. Please note that because the windows binaries ( qxl drivers and agent ) have not been released yet you won’t be able to get the full SPICE experience using this procedure. According to the spice website these windows binaries are to be released soon. So let’s begin.
Fedora has made it very simple to setup the required dependencies to get spice client and server up and running. Again, I’ll re-emphasize that this is procedure currently only works if you’re running Fedora 12 on your KVM host. Install the spice repository using the following commands.
sudo wget -P /etc/yum.repos.d/ http://spice-space.org/download/spice.repo sudo rpm --import http://spice-space.org/download/RPM-GPG-KEY-spice-fedora-12-x86_64
Next install the spice client and qemu packaged with the spice using the following commands.
sudo yum install spice-client sudo yum install qemu-spice
Now you are ready to give spice client a test run.
For this part you can either install a new guest machine or you can use an existing disk image that you’ve already installed using kvm. The only additional options you really need in order to get this “spiced” version of qemu up and running is the –spice option as shown below. Note that this package installs the qemu spiced binary at /usr/libexec/qemu-spice .
/usr/libexec/qemu-spice \ -hda /var/lib/libvirt/images/Centos4-Devel.qcow2 \ -m 512 \ -qxl 1 \ -spice port=5930,disable-ticketing &
The –qxl option specifies the number of qxl display devices. You can safely use this option even without qxl drivers since it supports standard VGA even when no drivers are installed. The spice option disable-ticketing enables a spice client connection with no password. Because we are just trying to get a basic working implementation of spice client and server we won’t be using any passwords. The port number is the port the spice server will be listening on. In this case I used 5930. When you execute that command you’ll probably see lots out output to your terminal similar to below.
Don’t worry about this as it’s just status information.
Now you can startup your spice client using the following command assuming you installed the client and server on the same machine.
/usr/bin/spicec –h localhost –p 5930
If you installed client and server on separate machines then replace localhost with the ip address of your server. Now you’ll see your spice client window startup. Below is a snapshot of what your spice client window should look like.
NOTE: To release your cursor from the guest you need to use key combination of Shift+F12
If you’re curious about SPICE and you have a KVM host running Fedora, 12 go ahead and give this procedure a try. As mentioned earlier this is the most basic implementation and so you won’t get the full SPICE experience due to lack of qxl driver and guest agent availability. I think it would be nice to eventually see integration of spice into virt-manager but it might be some time before we see this due to the work involved. In any case you at least have the components to work with SPICE.