From: "Fabian Grünbichler" <f.gruenbichler@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH qemu-server 2/2] config: make attempts at writing out NoWrite configs fatal
Date: Tue, 18 Feb 2025 14:08:12 +0100 [thread overview]
Message-ID: <20250218130812.458974-3-f.gruenbichler@proxmox.com> (raw)
In-Reply-To: <20250218130812.458974-1-f.gruenbichler@proxmox.com>
attempting to write such a config is already a bug, and execution should not
continue in this case. very often a write of the config will be followed by
reloading it, expecting changes to be persisted and possibly missing
re-checking of the original reason for marking the config as NoWrite.
Signed-off-by: Fabian Grünbichler <f.gruenbichler@proxmox.com>
---
this might be a bit opinionated, but I'd rather err on the side of
caution/aborting here..
PVE/QemuConfig/NoWrite.pm | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/PVE/QemuConfig/NoWrite.pm b/PVE/QemuConfig/NoWrite.pm
index 02e5f158..53a34990 100644
--- a/PVE/QemuConfig/NoWrite.pm
+++ b/PVE/QemuConfig/NoWrite.pm
@@ -16,8 +16,7 @@ sub mark_config {
sub write_config {
my ($class, $vmid, $conf) = @_;
- log_warn("refusing to write temporary configuration");
- return;
+ die("refusing to write temporary configuration\n");
}
1;
--
2.39.5
_______________________________________________
pve-devel mailing list
pve-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
next prev parent reply other threads:[~2025-02-18 13:08 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-12 11:04 [pve-devel] [PATCH-SERIES qemu-server v3 0/3] fix #6007: fix PBS template backup for certain configurations Fiona Ebner
2025-02-12 11:04 ` [pve-devel] [PATCH qemu-server v3 1/3] backup: also restore VM power state for early failures Fiona Ebner
2025-02-12 11:04 ` [pve-devel] [PATCH qemu-server v3 2/3] config: add special class that prevents writing the configuration Fiona Ebner
2025-02-18 11:03 ` Wolfgang Bumiller
2025-02-18 13:08 ` [pve-devel] [PATCH qemu-server 0/2] follow-ups for "v3 fix #6007: fix PBS template backup for certain configurations" Fabian Grünbichler
2025-02-18 13:08 ` [pve-devel] [PATCH qemu-server 1/2] config: revamp NoWrite interface Fabian Grünbichler
2025-02-18 13:08 ` Fabian Grünbichler [this message]
2025-02-18 13:18 ` [pve-devel] [PATCH qemu-server 0/2] follow-ups for "v3 fix #6007: fix PBS template backup for certain configurations" Fiona Ebner
2025-02-12 11:04 ` [pve-devel] [PATCH qemu-server v3 3/3] fix #6007: template backup: use minimized configuration for handling the full vm start Fiona Ebner
2025-02-18 14:20 ` [pve-devel] applied-series: [PATCH-SERIES qemu-server v3 0/3] fix #6007: fix PBS template backup for certain configurations Fabian Grünbichler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250218130812.458974-3-f.gruenbichler@proxmox.com \
--to=f.gruenbichler@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.