From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [IPv6:2a0f:8001:1:32::40]) by lore.proxmox.com (Postfix) with ESMTPS id B6A261FF150 for ; Mon, 06 Jul 2026 16:03:58 +0200 (CEST) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id 79E872146B; Mon, 06 Jul 2026 16:03:58 +0200 (CEST) From: Maximiliano Sandoval To: pve-devel@lists.proxmox.com Subject: [PATCH guest-common 2/2] fix #1964: replication config: add a setting to skip freezing guest filesystems Date: Mon, 6 Jul 2026 16:03:52 +0200 Message-ID: <20260706140354.475972-3-m.sandoval@proxmox.com> X-Mailer: git-send-email 2.47.3 In-Reply-To: <20260706140354.475972-1-m.sandoval@proxmox.com> References: <20260706140354.475972-1-m.sandoval@proxmox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1783346628679 X-SPAM-LEVEL: Spam detection results: 0 DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment (newer systems) 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: 3Z3QBJ6HDNS2XAHUQBJF6J37RBUYPU6M X-Message-ID-Hash: 3Z3QBJ6HDNS2XAHUQBJF6J37RBUYPU6M X-MailFrom: m.sandoval@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: We log an entry when a freeze would have happened and we skip it based on replication.cfg. Signed-off-by: Maximiliano Sandoval --- src/PVE/Replication.pm | 7 +++++++ src/PVE/ReplicationConfig.pm | 8 ++++++++ 2 files changed, 15 insertions(+) diff --git a/src/PVE/Replication.pm b/src/PVE/Replication.pm index ba4c2c1..79f0be4 100644 --- a/src/PVE/Replication.pm +++ b/src/PVE/Replication.pm @@ -300,6 +300,13 @@ sub replicate { my $conf = $guest_class->load_config($vmid); my ($running, $freezefs) = $guest_class->__snapshot_check_freeze_needed($vmid, $conf, 0); + if ($jobcfg->{'skip-freeze-fs'}) { + $logfunc->( + "replication job configured with 'skip-freeze-fs' enabled, not freezing guest filesystems" + ) if $freezefs; + $freezefs = 0; + } + my $volumes = $guest_class->get_replicatable_volumes( $storecfg, $vmid, diff --git a/src/PVE/ReplicationConfig.pm b/src/PVE/ReplicationConfig.pm index cf9ee01..fcedbfe 100644 --- a/src/PVE/ReplicationConfig.pm +++ b/src/PVE/ReplicationConfig.pm @@ -96,6 +96,13 @@ my $defaultData = { format => 'pve-node', optional => 1, }, + 'skip-freeze-fs' => { + description => + "Wether to skip freezing & thawing the guest's filesystems during replication", + type => 'boolean', + optional => 1, + default => 0, + }, }, }; @@ -335,6 +342,7 @@ sub options { schedule => { optional => 1 }, remove_job => { optional => 1 }, source => { optional => 1 }, + 'skip-freeze-fs' => { optional => 1 }, }; } -- 2.47.3