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 B9CB71FF09F for ; Tue, 01 Dec 2026 10:11:29 +0100 (CET) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id AE51C20CAE; Tue, 01 Dec 2026 10:11:18 +0100 (CET) From: Dietmar Maurer To: pbs-devel@lists.proxmox.com Subject: [PATCH proxmox-backup 5/5] client: backup: add option to fail on files that cannot be read Date: Tue, 1 Dec 2026 10:11:11 +0100 Message-ID: <20261201091111.940190-6-dietmar@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20261201091111.940190-1-dietmar@proxmox.com> References: <20261201091111.940190-1-dietmar@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SPAM-LEVEL: Spam detection results: 1 AWL -0.446 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) KAM_LAZY_DOMAIN_SECURITY 1 Sending domain does not have any anti-forgery methods RDNS_NONE 1.274 Delivered to internal network by a host with no rDNS SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_NONE 0.001 SPF: sender does not publish an SPF Record Message-ID-Hash: E3KESO2G6HK3X35EV7YLBVRYIUTIZ6QP X-Message-ID-Hash: E3KESO2G6HK3X35EV7YLBVRYIUTIZ6QP X-MailFrom: dietmar@zilli.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 Backup Server development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: A backup leaves out files and directories it cannot read for lack of permission, and only warns about them. Users who need complete backups, for example of folders they expect to own entirely, can now make it fail instead, so an incomplete snapshot never gets stored. Signed-off-by: Dietmar Maurer --- proxmox-backup-client/src/main.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/proxmox-backup-client/src/main.rs b/proxmox-backup-client/src/main.rs index e71677633..b4bc54d4e 100644 --- a/proxmox-backup-client/src/main.rs +++ b/proxmox-backup-client/src/main.rs @@ -788,6 +788,14 @@ fn spawn_catalog_upload( optional: true, default: false, }, + "fail-on-access-denied": { + type: Boolean, + description: + "Fail on files and directories that cannot be read for lack of permission, \ + instead of leaving them out of the backup with a warning.", + optional: true, + default: false, + }, "no-cache": { type: Boolean, description: "Bypass local datastore cache for network storages.", @@ -806,6 +814,7 @@ async fn create_backup( change_detection_mode: Option, dry_run: bool, skip_e2big_xattr: bool, + fail_on_access_denied: bool, no_cache: bool, limit: ClientRateLimitConfig, _info: &ApiMethod, @@ -1243,7 +1252,7 @@ async fn create_backup( previous_ref, max_cache_size, on_access_denied: None, - fail_on_access_denied: false, + fail_on_access_denied, }; let upload_options = UploadOptions { -- 2.47.3