]> git.proxmox.com Git - qemu-server.git/commitdiff
pending : add disk hot-unplug
authorAlexandre Derumier <aderumier@odiso.com>
Fri, 2 Jan 2015 14:15:58 +0000 (15:15 +0100)
committerDietmar Maurer <dietmar@proxmox.com>
Wed, 7 Jan 2015 05:54:57 +0000 (06:54 +0100)
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
PVE/QemuServer.pm

index cdb7834d3d877f32ec8fa58a94296fda44e46a21..0c70c18e498d5bece1ae82284022b24eaeb2c637 100644 (file)
@@ -3656,7 +3656,9 @@ sub vmconfig_hotplug_pending {
                die "skip\n" if !$hotplug;
                vm_deviceunplug($vmid, $conf, $opt);
            } elsif (valid_drivename($opt)) {
-               die "skip\n"; # we do not allow to hot-remove disk?             
+               die "skip\n" if !$hotplug;
+               vm_deviceunplug($vmid, $conf, $opt);
+               vmconfig_register_unused_drive($storecfg, $vmid, $conf, parse_drive($opt, $conf->{$opt}));
            } else {
                die "skip\n";
            }