[pve-devel] [PATCH qemu-server] vzdump: exclude efidisks from backups of non-OVMF machines

Stefan Reiter s.reiter at proxmox.com
Mon Feb 17 10:34:16 CET 2020


Machines running with SeaBIOS don't have the efidisk attached, so QEMU
cannot back it up and fails with "unknown drive".

Signed-off-by: Stefan Reiter <s.reiter at proxmox.com>
---
 PVE/VZDump/QemuServer.pm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/PVE/VZDump/QemuServer.pm b/PVE/VZDump/QemuServer.pm
index 3d9c61a..7695ad6 100644
--- a/PVE/VZDump/QemuServer.pm
+++ b/PVE/VZDump/QemuServer.pm
@@ -84,6 +84,9 @@ sub prepare {
 		die "disk '$ds' '$volid' (iothread=on) can't use backup feature with running QEMU " .
 		    "version < 4.0.1! Either set backup=no for this drive or upgrade QEMU and restart VM\n";
 	    }
+	} elsif ($ds =~ m/^efidisk/ && (!defined($conf->{bios}) || $conf->{bios} ne 'ovmf')) {
+	    $self->loginfo("excluding '$ds' (efidisks can only be backed up when BIOS is set to 'ovmf')");
+	    return;
 	} else {
 	    my $log = "include disk '$ds' '$volid'";
 	   if (defined $drive->{size}) {
-- 
2.20.1





More information about the pve-devel mailing list