From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) by lore.proxmox.com (Postfix) with ESMTPS id 556081FF14C for ; Fri, 15 May 2026 14:36:02 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 6A7DCD329; Fri, 15 May 2026 14:35:59 +0200 (CEST) Message-ID: Date: Fri, 15 May 2026 14:35:23 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Beta Subject: superseded: [PATCH qemu-server v4 0/3] improve guest cleanup handling From: Dominik Csapak To: pve-devel@lists.proxmox.com References: <20260515100842.1980636-1-d.csapak@proxmox.com> Content-Language: en-US In-Reply-To: <20260515100842.1980636-1-d.csapak@proxmox.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1778848516998 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.050 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment 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: BB4MTFLKI5X3FEIPO23HQNDJ4WEQ5ZQ6 X-Message-ID-Hash: BB4MTFLKI5X3FEIPO23HQNDJ4WEQ5ZQ6 X-MailFrom: d.csapak@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: superseded by v5: https://lore.proxmox.com/pve-devel/20260515122437.3153051-1-d.csapak@proxmox.com/T/#t On 5/15/26 12:09 PM, Dominik Csapak wrote: > First we make the cleanup handling more consistent (1/3) > then we check explicitely for the backup lock to improve the error > message for stop backup mode (2/3) > and then we fix #7119 by waiting up to 30s for a possibly still running > guest to stop (e.g. this can occur when using usb passthrouh) (3/3) > > changes from v3: > * update version in preinst check > * add #DEBHELPER# to preinst > * consistently use /run/ instead of /var/run > * make get_cleanup_flag_path public and use that for mocking in tests > * style fixes > * use non-deprecated is_running helper > * improve warning message > > changes from v2/RFC: > * use 'vm_running_locally' for getting the pid > * improve error messages > * use a 'use_old_cleanup' flag that will be auto-removed by a reboot > to signal if we can use the new cleanup logic or the old > > Dominik Csapak (3): > cleanup: refactor to make cleanup flow consistent > qm cleanup: die early when encountering a running stop mode backup > fix #7119: qm cleanup: wait for process exiting for up to 30 seconds > > debian/preinst | 18 +++++++++++++++ > src/PVE/CLI/qm.pm | 39 ++++++++++++++++++++++++++++---- > src/PVE/QemuServer.pm | 14 ++++++++++++ > src/PVE/QemuServer/RunState.pm | 29 ++++++++++++++++++++++++ > src/test/MigrationTest/QmMock.pm | 11 +++++++++ > 5 files changed, 106 insertions(+), 5 deletions(-) > create mode 100755 debian/preinst >