KVM Guest Management With Virt-Manager On Ubuntu 8.10
Author: Falko Timme
Last edited 02/05/2009
Virt-Manager (Virtual Machine Manager) is a graphical interface for managing KVM and Xen guests on the local and also on remote systems. You can use it to start, stop, pause, create, and delete guests, and you can connect to the guests using the graphical console. This guide shows how you can use it to manage KVM guests on an Ubuntu 8.10 desktop.
I do not issue any guarantee that this will work for you!
1 Preliminary Note
Make sure that you have a KVM host (can be on the same machine or on a remote system) that you can connect to using virt-manager. You can use this guide to set up KVM on an Ubuntu 8.10 host: Virtualization With KVM On Ubuntu 8.10.
Creating guests is supported only if virt-manager is installed directly on the KVM host.
2 Installing Virt-Manager
Open the Synaptic Package Manager (System > Administration > Synaptic Package Manager):
Type in your password:
In Synaptic, search for virt-manager...
... and virt-viewer and mark both packages for installation; click on Apply afterwards:
Confirm your selection by clicking on Apply again:
Afterwards, both packages and their dependencies are installed:
Click on Close afterwards and leave Synaptic:
2.1 Make Virt-Manager Run With root Privileges
Normally virt-manager is run as a normal user (i.e., without root privileges). This is fine as long as you only want to start, stop, or pause KVM guests. If you want to create or delete KVM guests (works only if KVM is installed on the same system!), virt-manager must be run with root privileges.
If KVM is installed on the same system as virt-manager, and you want to create or delete KVM guests, open a terminal (Applications > Accessories > Terminal) and open the file /usr/bin/virt-manager:
sudo gedit /usr/bin/virt-manager
Insert the word sudo between exec and python so that the file looks as follows:
#!/bin/sh exec sudo python "/usr/share/virt-manager/virt-manager.py" "$@"
That's it - virt-manager will be executed with root privileges from now on.