[Pkg-libvirt-maintainers] Bug#1006324: In debian bookworm: virt-install fails to reinstall VM when automatic UEFI firmware is set

Katerina Koukiou kkoukiou at redhat.com
Wed Feb 23 15:46:48 GMT 2022


Package: virtinst
Version: 1:3.2.0-3

Package: apparmor
Version: 3.0.3-6

When trying to re-install an existing VM with uefi boot set up using the
recently introduced `--reinstall` option apparmor makes the installation
fail with the following error:

Could not open '/var/lib/libvirt/qemu/nvram/test_VARS.fd': Permission denied

Steps to reproduce:

Create a VM:

root at debian:~# virt-install --connect qemu:///system --quiet --os-variant
fedora28 --memory 128 --name test --wait -1 --disk size=0.125,format=qcow2
--graphics vnc,listen=127.0.0.1 --graphics spice,listen=127.0.0.1
--print-xml 1 > /tmp/test1.xml

Edit the VM configuration to enable automatic UEFI boot by changing the
<os> like follows:

- <os>

+ <os firmware='efi'>


Define the VM:

root at debian:~# virsh define /tmp/test1.xml

Start VM installation:

root at debian:~#  virt-install --connect qemu:///system --reinstall test
--wait -1 --noautoconsole --cdrom /var/lib/libvirt/novell.iso --autostart
WARNING  No operating system detected, VM performance may suffer. Specify
an OS with --os-variant for optimal results.

Starting install...
ERROR    internal error: process exited while connecting to monitor:
2022-02-23T15:27:44.497553Z qemu-system-x86_64: -blockdev
{"driver":"file","filename":"/var/lib/libvirt/qemu/nvram/test_VARS.fd","node-name":"libvirt-pflash1-storage","auto-read-only":true,"discard":"unmap"}:
Could not open '/var/lib/libvirt/qemu/nvram/test_VARS.fd': Permission denied
Domain installation does not appear to have been successful.
If it was, you can restart your domain by running:
  virsh --connect qemu:///system start test
otherwise, please restart your installation.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-libvirt-maintainers/attachments/20220223/40968e5e/attachment.htm>


More information about the Pkg-libvirt-maintainers mailing list