Site icon DesignLinux

How to Create Virtual Machines in KVM Using Virt-Manager

As you get started, ensure that the KVM hypervisor is installed on your system. An acronym for Kernel-based Virtual Machine, KVM is a combination of kernel modules & utilities needed to run virtual machines on a host system. These include QEMU, virt-install, libvirtd daemon, virt-manager and so many more.

We have elaborate articles on:

For this guide, I’ll be working on Ubuntu 20.04 to illustrate how virt-manager can be used to create as well as manage virtual machines.

Creating Virtual Machines using Virt-Manager

To start off, launch virt-manager. This can be achieved in two ways. You can use the application manager to search for the virt-manager application as shown.

Launch Virt-Manager

If you are running on a terminal, run the following command:

$ sudo virt-manager

This will launch the Virtual Machines manager GUI application as shown.

Virtual Machine Manager

To get started with creating a virtual machine, click on the ‘New virtual machine’ icon at the top left corner, just below the ‘File’ menu item.

New Virtual Machine

The next step presents a list of options that you can choose from when selecting your preferred operating system.

Be sure to select the option that suits you. In my case, I already have a Debian 10 ISO image on my local system. Therefore, I’ll select the first option and click the ‘Forward’ button.

Create New Virtual Machine

Next, click on the ‘browse local’ button and select your disk image.

Choose Disk Image

In the image below, the ISO image has already been selected. Accept the defaults for ‘OS type’ and ‘Version’ and click ‘Forward’.

Choose OS Type

In the next step, specify the RAM size and the number of CPU cores to be assigned and click ‘Forward’.

Choose Memory and CPU Settings

Next, specify the disk space for the virtual machine and hit ‘Forward’.

Set Disk Space for VM

In the last step, provide the preferred name of the virtual machine and confirm that all the other VM details are okay. Additionally, you can choose to configure the Network preferences. For example, you can opt to go with the default NAT network or change to a bridged network if you want your guest machine to be in the same network as the host.

To start the virtual machine, click on the ‘Finish’ button.

Finish VM Installation

This launches the virtual machine. For those who have installed Debian 10 before, this step should look familiar. However, we will not complete the installation as our main focus is creating and managing virtual machines using KVM. We have an elaborate guide on how to install Debian 10.

Debian VM Installation

That’s pretty much it. In the next article, we will see how to manage KVM virtual machines with Virt-manager or you can also use cockpit to manage virtual machines. If you have any queries about this article, feel free to ask in the comments.

Source: access.redhat.com

Exit mobile version