From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [45.144.208.40]) by lore.proxmox.com (Postfix) with ESMTPS id C28EB1FF0C0 for ; Wed, 18 Nov 2026 12:08:03 +0100 (CET) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id 035DD218C4; Wed, 18 Nov 2026 12:07:22 +0100 (CET) From: Thomas Lamprecht To: pve-devel@lists.proxmox.com Subject: [PATCH manager 09/15] ui: migrate: recheck preconditions if the target changed meanwhile Date: Wed, 18 Nov 2026 12:05:16 +0100 Message-ID: <20261118110705.595989-10-t.lamprecht@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20261118110705.595989-1-t.lamprecht@proxmox.com> References: <20261118110705.595989-1-t.lamprecht@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1795000030768 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.174 Adjusted score from AWL reputation of From: address DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) RCVD_IN_DNSWL_MED -2.3 Sender listed at https://www.dnswl.org/, medium trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: HKYTIKM35SWWPDJOOUIHY7LJWMTHJ3HT X-Message-ID-Hash: HKYTIKM35SWWPDJOOUIHY7LJWMTHJ3HT X-MailFrom: t.lamprecht@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: While the migration preconditions of a VM are being checked, a check requested for a newly selected target node is skipped. If the target changed after the running check read it, the dialog showed the result for the previous target, which can block the migration to a suitable node or allow it to an unsuitable one. Redo the check in that case. Also end a check whose dialog was closed meanwhile, instead of failing on the fields that are gone. Signed-off-by: Thomas Lamprecht --- www/manager6/window/Migrate.js | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/www/manager6/window/Migrate.js b/www/manager6/window/Migrate.js index 23090b7aa..40bca4228 100644 --- a/www/manager6/window/Migrate.js +++ b/www/manager6/window/Migrate.js @@ -206,6 +206,9 @@ Ext.define('PVE.window.Migrate', { } else { await me.checkLxcPreconditions(resetMigrationPossible); } + if (me.destroyed) { + return; + } // Only allow nodes where the local storage is available in case of offline migration // where storage migration is not possible @@ -243,6 +246,9 @@ Ext.define('PVE.window.Migrate', { me.fetchingNodeMigrateInfo = false; return; } + if (me.destroyed) { + return; + } const target = me.lookup('pveNodeSelector').value; let targetCapabilities = {}; @@ -261,6 +267,15 @@ Ext.define('PVE.window.Migrate', { me.fetchingNodeMigrateInfo = false; + if (me.destroyed) { + return; + } + // a check for a target selected meanwhile was skipped, so redo it for the current one + if (me.lookup('pveNodeSelector').value !== target) { + await me.checkQemuPreconditions(resetMigrationPossible); + return; + } + if (migrateStats.running) { vm.set('running', true); } @@ -503,6 +518,9 @@ Ext.define('PVE.window.Migrate', { me.fetchingNodeMigrateInfo = false; return; } + if (me.destroyed) { + return; + } if (migrateStats.running) { vm.set('running', true); -- 2.47.3