[pve-devel] [PATCH qemu-server v5 15/16] migration: attempt to clean up potential left-over fleecing images
Fiona Ebner
f.ebner at proxmox.com
Mon Jan 27 12:29:22 CET 2025
Clean up left-over fleecing images before the guest is migrated to a
different node and they'd really become orphaned.
Suggested-by: Fabian Grünbichler <f.gruenbichler at proxmox.com>
Signed-off-by: Fiona Ebner <f.ebner at proxmox.com>
---
PVE/QemuMigrate.pm | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/PVE/QemuMigrate.pm b/PVE/QemuMigrate.pm
index 625fd1f7..f02360ad 100644
--- a/PVE/QemuMigrate.pm
+++ b/PVE/QemuMigrate.pm
@@ -177,6 +177,13 @@ sub prepare {
my $storecfg = $self->{storecfg} = PVE::Storage::config();
+ # updates the configuration, so ordered before saving the configuration in $self
+ eval {
+ PVE::QemuConfig::cleanup_fleecing_images(
+ $vmid, $storecfg, sub { $self->log($_[0], $_[1]); });
+ };
+ $self->log('warn', "attempt to clean up left-over fleecing images failed - $@") if $@;
+
# test if VM exists
my $conf = $self->{vmconf} = PVE::QemuConfig->load_config($vmid);
--
2.39.5
More information about the pve-devel
mailing list