Libvirt: Difference between revisions

Setup: runAsRoot's default is true.
UEFI with OVMF: This is not necessary anymore. See https://github.com/NixOS/nixpkgs/blob/98ce61be576896913274454adf9506d15d1e63f7/nixos/modules/virtualisation/libvirtd.nix#L415
Line 30: Line 30:


=== UEFI with OVMF ===
=== UEFI with OVMF ===
Enable UEFI firmware support, following Qemu configuration for your local user is required
{{file|~/.config/libvirt/qemu.conf|nix|<nowiki>
# Adapted from /var/lib/libvirt/qemu.conf
# Note that AAVMF and OVMF are for Aarch64 and x86 respectively
nvram = [ "/run/libvirt/nix-ovmf/AAVMF_CODE.fd:/run/libvirt/nix-ovmf/AAVMF_VARS.fd", "/run/libvirt/nix-ovmf/OVMF_CODE.fd:/run/libvirt/nix-ovmf/OVMF_VARS.fd" ]
</nowiki>}}


See [https://ostechnix.com/enable-uefi-support-for-kvm-virtual-machines-in-linux/ this tutorial] on how to run a guest machine in UEFI mode using <code>virt-manager</code>.
See [https://ostechnix.com/enable-uefi-support-for-kvm-virtual-machines-in-linux/ this tutorial] on how to run a guest machine in UEFI mode using <code>virt-manager</code>.