From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 6A4D461B90 for ; Thu, 22 Oct 2020 12:30:33 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 10C881F079 for ; Thu, 22 Oct 2020 12:30:33 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [212.186.127.180]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id B2B721EFBE for ; Thu, 22 Oct 2020 12:30:29 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id 6ACBF45ED7 for ; Thu, 22 Oct 2020 12:30:29 +0200 (CEST) From: Fabian Ebner To: pve-devel@lists.proxmox.com Date: Thu, 22 Oct 2020 12:30:09 +0200 Message-Id: <20201022103017.19715-1-f.ebner@proxmox.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 0 AWL -0.410 Adjusted score from AWL reputation of From: address KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment 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 URIBL_BLOCKED 0.001 ADMINISTRATOR NOTICE: The query to URIBL was blocked. See http://wiki.apache.org/spamassassin/DnsBlocklists#dnsbl-block for more information. [vzdump.pm, backupinfo.pm, backup.pm] URIBL_SBL 0.644 Contains an URL's NS IP listed in the Spamhaus SBL blocklist [backup.pm] URIBL_SBL_A 0.1 Contains URL's A record listed in the Spamhaus SBL blocklist [backup.pm] Subject: [pve-devel] [PATCH-SERIES v2 manager] Make backup with IDs for non-existent guests visibly fail X-BeenThere: pve-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox VE development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 22 Oct 2020 10:30:33 -0000 #1 and #2 are just cleanups #3 and #4 make the necessary changes for the improved behavior by ensuring that exec_backup_task will cleanly fail when there is no plugin specified, and then including the orphaned IDs without assigning them a plugin. This is closer to the behavior of PVE 6.0 and ensures that the backup task is marked as failed, and the mail notification includes an error for the orphaned IDs. #5 ensures that the IDs are still numerically ordered when there are non-existing guests #6 and #7 are minor improvements and can be applied independently #8 is an RFC and changes the data structure returned by get_included_guests Changes from v1: * everything, as the approach is different Fabian Ebner (8): remove unused variable remove out-of-date comment only use plugin after truthiness check backup: include IDs for non-existent guests order guest IDs numerically in exec_backup sort the skip list numerically simplify get_included_vmids function don't group by node in get_included_guests PVE/API2/Backup.pm | 23 ++-- PVE/API2/BackupInfo.pm | 18 +--- PVE/API2/VZDump.pm | 19 +++- PVE/VZDump.pm | 68 +++++++----- test/vzdump_guest_included_test.pl | 163 ++++++++++++++++++++++++++--- 5 files changed, 212 insertions(+), 79 deletions(-) -- 2.20.1