Support #659
Install Qemu and Virt-Manager on Arch
Description
This is a simple guide for getting started with virt-manager on Arch Linux.
Prepare the Environment¶
- Make sure the system is up to date:
sudo pacman -Syu
- Install libvirt and a few dependencies:
sudo pacman -S libvirt qemu ebtables dnsmasq bridge-utils openbsd-netcat
- NOTE: Extra architectures can be installed by installing the qemu-arch-extra package
sudo pacman -S qemu-arch-extra
- NOTE: Extra architectures can be installed by installing the qemu-arch-extra package
- Create the qemu user and added it to kvm group:
sudo groupadd kvm sudo useradd -MrG kvm qemu
- Edit the qemu config:
sudo nano /etc/libvirt/qemu.conf
- And set the user and groups that qemu will use:
user = "qemu" group = "kvm"
- And set the user and groups that qemu will use:
- Start and enable libvirtd.service at boot:
sudo systemctl enable libvirtd sudo systemctl start libvirtd
- Change the group authorized to access the RW daemon socket, create the following file:
sudo nano /etc/polkit-1/rules.d/49-org.libvirt.unix.manager.rules
- And add the following:
/* Allow users in kvm group to manage the libvirt daemon without authentication */ polkit.addRule(function(action, subject) { if (action.id == "org.libvirt.unix.manage" && subject.isInGroup("kvm")) { return polkit.Result.YES; } });
- And add the following:
- Then add the bob user to the kvm group:
usermod -aG kvm bob
- Log out and then log back in for the permissions to take effect.
Install virt-manager¶
- Install virt-manager hypervisor:
pacman -S virt-manager
- Create a new QEMU/KVM Session connection