From: Fiona Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [PATCH qemu-server 2/8] api: clone/import: fix check if agent is enabled
Date: Tue, 24 Mar 2026 14:50:42 +0100 [thread overview]
Message-ID: <20260324135325.120749-3-f.ebner@proxmox.com> (raw)
In-Reply-To: <20260324135325.120749-1-f.ebner@proxmox.com>
Just checking whether the configuration is present does not mean that
the guest agent is enabled. Explicitly check the 'enabled' property.
In case of snapshot, this is already done. This avoids a log message
about the agent not running, since there is no device added to the
QEMU commandline for communicating with the agent if disabled.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
src/PVE/API2/Qemu.pm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/PVE/API2/Qemu.pm b/src/PVE/API2/Qemu.pm
index b409610c..1752f46a 100644
--- a/src/PVE/API2/Qemu.pm
+++ b/src/PVE/API2/Qemu.pm
@@ -374,7 +374,7 @@ my $import_from_volid = sub {
my ($src_storeid) = PVE::Storage::parse_volume_id($src_volid);
- my $qga = $src_conf->{agent}
+ my $qga = PVE::QemuServer::Agent::get_qga_key($src_conf, 'enabled')
&& (PVE::QemuServer::Agent::get_qga_key($src_conf, 'guest-fsfreeze') // 1);
return PVE::QemuServer::clone_disk(
@@ -4562,7 +4562,7 @@ __PACKAGE__->register_method({
$dest_info->{efisize} = PVE::QemuServer::get_efivars_size($oldconf)
if $opt eq 'efidisk0';
- my $qga = $oldconf->{agent}
+ my $qga = PVE::QemuServer::Agent::get_qga_key($oldconf, 'enabled')
&& (PVE::QemuServer::Agent::get_qga_key($oldconf, 'guest-fsfreeze') // 1);
my $newdrive = PVE::QemuServer::clone_disk(
--
2.47.3
next prev parent reply other threads:[~2026-03-24 13:53 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-24 13:50 [PATCH-SERIES qemu-server 0/8] fix #7383: agent: fsfreeze: skip freeze if already frozen Fiona Ebner
2026-03-24 13:50 ` [PATCH qemu-server 1/8] agent: fs thaw: check command result Fiona Ebner
2026-03-25 21:20 ` applied: " Thomas Lamprecht
2026-03-24 13:50 ` Fiona Ebner [this message]
2026-03-25 21:20 ` applied: [PATCH qemu-server 2/8] api: clone/import: fix check if agent is enabled Thomas Lamprecht
2026-03-24 13:50 ` [PATCH qemu-server 3/8] backup: freeze: " Fiona Ebner
2026-03-25 21:20 ` applied: " Thomas Lamprecht
2026-03-24 13:50 ` [PATCH qemu-server 4/8] agent: parse: change signature to take property string rather than full VM config Fiona Ebner
2026-03-24 13:50 ` [PATCH qemu-server 5/8] agent: get qga key: " Fiona Ebner
2026-03-24 13:50 ` [PATCH qemu-server 6/8] clone disk/block jobs: change signatures to take guest agent property string Fiona Ebner
2026-03-24 13:50 ` [PATCH qemu-server 7/8] agent: fsfreeze: harmonize checks for guest fs freeze Fiona Ebner
2026-03-25 21:16 ` Thomas Lamprecht
2026-03-24 13:50 ` [PATCH qemu-server 8/8] fix #7383: agent: fsfreeze: skip freeze if already frozen Fiona Ebner
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=20260324135325.120749-3-f.ebner@proxmox.com \
--to=f.ebner@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.