```bash
# /etc/portage/package.use/libvirt-and-virt-manager
# libvirt and virt-manager.
app-crypt/p11-kit abi_x86_32
app-emulation/libvirt fuse macvtap numa pcap policykit vepa virt-network
app-emulation/virt-manager gui policykit
net-dns/dnsmasq script
net-libs/gnutls pkcs11 tools
net-misc/spice-gtk usbredir
# QEMU
app-emulation/qemu QEMU_SOFTMMU_TARGETS: arm x86_64 sparc QEMU_USER_TARGETS: x86_64
app-emulation/qemu aio curl gtk ncurses nls opengl sdl spice usb usbredir virgl virtfs
```
```bash
$ sudo emerge -av app-emulation/libvirt app-emulation/qemu app-emulation/virt-manager
```
```bash
# /etc/libvirt/qemu.conf
user = "qemu"
group = "qemu"
```
```bash
# /etc/libvirt/libvirtd.conf
auth_unix_ro = "none"
auth_unix_rw = "none"
unix_sock_group = "libvirt"
unix_sock_ro_perms = "0777"
unix_sock_rw_perms = "0770"
```
```bash
$ sudo usermod -aG libvirt <user>
```
```bash
$ sudo rc-service libvirtd start
$ sudo rc-update add libvirtd default
```
1. Open the Virtual Machine Manager (`virt-manager`).
2. Go to *File > Add Connection*.
3. In the dropdown menu next to *Hypervisor*, select *QEMU/KVM user session*.
4. Check the box next to *Autoconnect*.
5. Click *Connect*.
You can use the default storage pool located at `~/.local/share/images`, or you can set up your own.
1. Double-click on *QEMU/KVM User session*.
2. Click on the *Storage* tab at the top.
3. For each storage pool you'd like to create, click on the plus icon at the bottom left.
4. Give the storage pool a name.
5. In the dropdown next to *Type*, select the appropriate type for the storage pool. In most cases, it will be *dir: Filesystem Directory*.
6. Click *Browse* and find where the storage pool would be accessible in the filesystem.
7. Click *Finish*.