KVM/QEMU setup for LainOS Layer 02 ~ OpenRC init scripts and default configuration for running virtual machines. https://lainos.net
Find a file
2026-07-19 17:31:16 -07:00
lainos-kvm fixed lainos-kvm 2026-07-19 17:31:16 -07:00
LICENSE Initial commit 2026-07-07 19:11:25 +02:00
README.md Update README.md 2026-07-07 19:12:33 +02:00

lainos-kvm

KVM/QEMU setup for LainOS Layer 02 ~ OpenRC init scripts and default configuration for running virtual machines.

Installation

doas pacman -S lainos-kvm qemu-full virt-manager libvirt dnsmasq

The package automatically:

  • Creates the kvm and libvirt groups and the libvirt-qemu user
  • Installs OpenRC init scripts for libvirtd and all modular daemons
  • Loads and persists the tun, kvm, and kvm_intel kernel modules
  • Sets up the default NAT network (192.168.122.0/24)
  • Sets up the default storage pool at /var/lib/libvirt/images
  • Registers all services in the default runlevel

Usage

Log out and back in after install for group membership to take effect, then:

sg libvirt -c "virt-manager"

Services

Service Role
libvirtd Main libvirt daemon
virtqemud QEMU driver daemon
virtnetworkd Network management daemon
virtstoraged Storage pool daemon
virtlogd VM console log daemon

Notes

  • AMD CPUs: replace kvm_intel with kvm_amd in /etc/modules-load.d/kvm.conf
  • VMs are stored at /var/lib/libvirt/images/ by default
  • Default network: NAT, 192.168.122.0/24, DHCP range 192.168.122.2-254