en	[[!meta title="virt-manager"]]

en	[*virt-manager*](http://virt-manager.org/) is a Free Software virtualization solution for Linux. *virt-manager* has a more complex interface than *GNOME Boxes* but it also has a more complete set of features.

en	virt-manager is the only virtualization solution that allows to use a Persistent Storage. See [[running Tails from a USB image|virt-manager#usb_image]].

en	The following instructions have been tested on Debian 12 (Bookworm).

en	Terminology

en	*virt-manager* is based on a set of lower level virtualization tools, going from the user interface to the hardware interactions with the processor. This terminology is a bit confusing and other documentation might mention the following tools:

en	*KVM* is the module of the Linux kernel that interacts with the virtualization features of the processor.

en	*QEMU* is the virtualization software that emulates virtual processors and peripherals based on *KVM* and that starts and stops virtual machines.

en	*libvirt* is a library that allows *virt-manager* to interact with the virtualization capabilities provided by *QEMU*.

en	*SPICE* is a protocol that allows to visualize the desktop of virtual machines.

en	*virt-manager* is the graphical interface that allows to create, configure, and run virtual machines.

en	Installation

en	To install *virt-manager* in Debian, execute the following command:

en	sudo apt install virt-manager libvirt-daemon-system

en	To install *virt-manager* in Ubuntu, execute the following command:

en	sudo apt install virt-manager libvirt-bin qemu-kvm

en	Running Tails from an ISO image

en	[[Download Tails as an ISO image|install/download-iso]], instead of a USB image.

en	Start *virt-manager*.

en	Double-click on **QEMU/KVM - Not Connected** to connect to the *QEMU* system of your host.

en	To create a new virtual machine, choose <span class="menuchoice"> <span class="guimenu">File</span>&nbsp;▸ <span class="guimenuitem">New Virtual Machine</span></span>.

en	In *step 1*, choose **Local install media (ISO image or CDROM)**.

en	In *step 2*:

en	**Choose ISO image**, then **Browse...**, and **Browse Local** to browse for the ISO image that you want to start from.

en	Unselect **Automatically detected from the installation media / source**.

en	Specify **Debian 11** in the field **Choose the operating system you are installing**.

en	In *step 3*, allocate at least 2048 MB of RAM.

en	In *step 4*, unselect **Enable storage for this virtual machine**.

en	In *step 5*:

en	Type a name of your choice for the new virtual machine.

en	Click **Finish** to start the virtual machine.

en	If you get the error message "Error starting domain: Requested operation is not valid: network 'default' is not active", then try to start the default virtual network:

en	<ol> <li>Click on **QEMU/KVM - Not Connected**.</li> <li>Choose <span class="menuchoice"> **Edit**&nbsp;▸ **Connection details**</span> to administer the connection to your local *QEMU* system.</li> <li>Click on **Virtual Networks** tab, then select the **default** virtual network in the left pane.</li> <li>Click on the [[!img lib/media-playback-start.png alt="Start Network" link=no class=symbolic]] icon on the bottom of the left pane to start the default virtual network.</li> </ol>

en	Running Tails from a USB image

en	Running Tails from a USB image is the only virtualization solution that allows you to use a Persistent Storage in a virtual machine.

en	[[Download Tails as a USB image|install/download]], instead of an ISO image.

en	Increase the size of the USB image to be at least 8 GB. This creates space for automatic upgrades and the Persistent Storage.

en	truncate -s size tails.img

en	size has to be at least `7200M`.

en	tails.img is the file name of the USB image that you want to resize.

en	In *step 1*, choose **Import existing disk image**.

en	Choose **Browse...**, and **Browse Local** to browse for the USB image that you want to start from.

en	In *step 4*:

en	Choose **Customize configuration before install**.

en	Click **Finish** to open the configuration view.

en	In the configuration view, choose **VirtIO Disk 1** or **IDE Disk 1**

en	Set **Disk bus** to **USB**.

en	Click **Apply**.

en	Expand the **Advanced options**.

en	Enable **Removable**.

en	Click **Apply** again.

en	Click **Begin Installation** in the top left corner to start the virtual machine.

en	After you start on the USB image, you can [[create a Persistent Storage|persistent_storage]] on it.
id	Sobald Sie von dem USB-Gerät gestartet haben, können Sie darauf einen [[beständigen Speicherbereich einrichten|first_steps/persistence/configure]].

en	Running Tails from a USB stick

en	To run Tails from a USB stick using *virt-manager*, first create a virtual machine running from an ISO image as described [[above|virt-manager#iso]].

en	Then do the following:

en	From the virtual machine window, choose **Virtual Machine**&nbsp;▸ **Shut Down**&nbsp;▸ **Force Off** to shut down the virtual machine.

en	Plug in the USB stick from which you want to run Tails.

en	Choose **View**&nbsp;▸ **Details** to edit the configuration of the virtual machine.

en	Click on the **Add Hardware** button on the bottom of the left pane.

en	Select **USB Host Device** in the left pane.

en	In the right pane, click on the device from which you want to run Tails, and click **Finish**.

en	You can keep the original ISO image connected as a virtual DVD to install Tails onto the USB stick if needed.

en	You can also disconnect the original ISO image and start directly from the USB stick once Tails is already installed on it. To do so:

en	Shut down the virtual machine.

en	In the configuration of the virtual machine, click on **SATA CDROM 1** in the left pane.

en	Click on the **Disconnect** button in the right pane.
id	Wählen Sie im linken Fensterbereich **USB Disk 1** aus.

en	To enable the USB stick as a boot option:

en	Click on **Boot Options** in the left pane.
id	Wählen Sie im linken Fensterbereich **USB Disk 1** aus.

en	Select the **USB** boot option corresponding to your USB device.

en	To start the virtual machine choose **View**&nbsp;▸ **Console** and then **Virtual Machine**&nbsp;▸ **Run**.

en	After you start on the USB device, you can [[create a Persistent Storage|persistent_storage]] on it.
id	Sobald Sie von dem USB-Gerät gestartet haben, können Sie darauf einen [[beständigen Speicherbereich einrichten|first_steps/persistence/configure]].

en	Troubleshooting

en	Graphics issues

en	Issues with graphics support in Tails running inside a virtual machine with *virt-manager* are common. The best solution can vary depending on the version of the virtualization software and on the virtual machine configuration. For example:

en	The *Auto resize VM with window* feature does not work in all configurations.

en	The video device that provides optimal graphics performance can be different depending on the version of the host operating system.

en	To troubleshoot such issues:

en	Ensure the virtual machine has a *Spice* display and a *Spice* channel configured, as opposed to *VNC* ones.

en	Try various virtual video device models.

en	Start with *Virtio* and *QXL* video devices: they generally give the best results. If they don't perform well for you, try every other video device model.

en	Try enabling or disabling the OpenGL and 3D acceleration options of the display and video device.