[pve-devel] [PATCH v2 qemu-server 5/5] vzdump: don't use dirty bitmap when VM was off

Stefan Reiter s.reiter at proxmox.com
Wed Aug 19 17:02:04 CEST 2020


There can't be a dirty bitmap when the VM was off, and if it was off we
will also shut it down after the backup, so no point in creating one.

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

diff --git a/PVE/VZDump/QemuServer.pm b/PVE/VZDump/QemuServer.pm
index c919aa9..f390344 100644
--- a/PVE/VZDump/QemuServer.pm
+++ b/PVE/VZDump/QemuServer.pm
@@ -513,7 +513,8 @@ sub archive_pbs {
 	    $params->{encrypt} = JSON::false;
 	}
 
-	$params->{'use-dirty-bitmap'} = JSON::true if $qemu_support->{'pbs-dirty-bitmap'};
+	$params->{'use-dirty-bitmap'} = JSON::true
+	    if $qemu_support->{'pbs-dirty-bitmap'} && $self->{vm_was_running};
 
 	$params->{timeout} = 60; # give some time to connect to the backup server
 
-- 
2.20.1





More information about the pve-devel mailing list