[pve-devel] [PATCH qemu-server 2/2] catch missing ovmf file

Noel Ullreich n.ullreich at proxmox.com
Tue Dec 6 14:11:38 CET 2022


check to see if the OVMF_VARS file actually exists. otherwise lines
3666 and 3673 break and give a cryptic error message

Signed-off-by: Noel Ullreich <n.ullreich at proxmox.com>
---
 PVE/QemuServer.pm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index 2a2f1f7..38f3145 100644
--- a/PVE/QemuServer.pm
+++ b/PVE/QemuServer.pm
@@ -3640,6 +3640,7 @@ sub config_to_command {
 
 	my ($ovmf_code, $ovmf_vars) = get_ovmf_files($arch, $d, $q35);
 	die "EFI base image '$ovmf_code' not found\n" if ! -f $ovmf_code;
+	die "EFI vars image '$ovmf_vars' not found\n" if ! -f $ovmf_vars;
 
 	my ($path, $format);
 	my $read_only_str = '';
-- 
2.30.2






More information about the pve-devel mailing list