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.rei...@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



_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel

Reply via email to