all lists on lists.proxmox.com
 help / color / mirror / Atom feed
From: Hannes Laimer <h.laimer@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH qemu-server] clone: drop the IPAM entries of a clone that failed
Date: Wed, 19 Aug 2026 15:51:20 +0200	[thread overview]
Message-ID: <20260819135120.933223-1-h.laimer@proxmox.com> (raw)

The clone puts its addresses on record before the last steps that can
still fail, and the cleanup afterwards took back the disks, the firewall
config and the configuration itself but left those behind.

Signed-off-by: Hannes Laimer <h.laimer@proxmox.com>
---
 src/PVE/API2/Qemu.pm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/PVE/API2/Qemu.pm b/src/PVE/API2/Qemu.pm
index 71247eec..b17f9bce 100644
--- a/src/PVE/API2/Qemu.pm
+++ b/src/PVE/API2/Qemu.pm
@@ -4720,6 +4720,9 @@ __PACKAGE__->register_method({
                     warn $@ if $@;
                 }
 
+                eval { PVE::QemuServer::Network::delete_ifaces_ipams_ips($newconf, $newid) };
+                warn $@ if $@;
+
                 PVE::Firewall::remove_vmfw_conf($newid);
 
                 unlink $conffile; # avoid races -> last thing before die
-- 
2.47.3





                 reply	other threads:[~2026-08-19 13:51 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260819135120.933223-1-h.laimer@proxmox.com \
    --to=h.laimer@proxmox.com \
    --cc=pve-devel@lists.proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal