]> git.proxmox.com Git - qemu-server.git/commitdiff
increase timeout for QMP block_resize
authorStefan Reiter <s.reiter@proxmox.com>
Tue, 30 Mar 2021 15:59:52 +0000 (17:59 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 30 Mar 2021 16:20:44 +0000 (18:20 +0200)
In testing this usually completes almost immediately, but in theory this
is a storage/IO operation and as such can take a bit to finish. It's
certainly not unthinkable that it might take longer than the default *3
seconds* we've given it so far. Make it a minute.

Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
PVE/QemuServer.pm

index 1c0b5c2d53a07ec8e8325c7069a8b8f423a4cce5..f9379f64d286ee0bbe86de7bec3d93278f8102ed 100644 (file)
@@ -4291,8 +4291,13 @@ sub qemu_block_resize {
     my $padding = (1024 - $size % 1024) % 1024;
     $size = $size + $padding;
 
-    mon_cmd($vmid, "block_resize", device => $deviceid, size => int($size));
-
+    mon_cmd(
+       $vmid,
+       "block_resize",
+       device => $deviceid,
+       size => int($size),
+       timeout => 60,
+    );
 }
 
 sub qemu_volume_snapshot {