From: Fiona Ebner <f.ebner@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH v2 qemu-server 1/2] fix #6207: vm status: return undef values when disk{read, write} cannot be queried
Date: Thu, 25 Sep 2025 14:25:08 +0200 [thread overview]
Message-ID: <20250925122829.70121-2-f.ebner@proxmox.com> (raw)
In-Reply-To: <20250925122829.70121-1-f.ebner@proxmox.com>
If disk read/write cannot be queried because of QMP timeout, they
should not be reported as 0, because a consumer of the RRD stats
cannot distinguish between 0 being an actual 0 value and 0 being an
indicator for the absence of the real value. The RRD graphs in the UI
will already show this correctly.
Signed-off-by: Fiona Ebner <f.ebner@proxmox.com>
---
Changes in v2:
* New approach, return undef instead of caching previous value.
src/PVE/QemuServer.pm | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/PVE/QemuServer.pm b/src/PVE/QemuServer.pm
index f7f85436..d6d0cb13 100644
--- a/src/PVE/QemuServer.pm
+++ b/src/PVE/QemuServer.pm
@@ -2731,8 +2731,8 @@ sub vmstatus {
$d->{netout} = 0;
$d->{netin} = 0;
- $d->{diskread} = 0;
- $d->{diskwrite} = 0;
+ $d->{diskread} = undef;
+ $d->{diskwrite} = undef;
$d->{template} = 1 if PVE::QemuConfig->is_template($conf);
--
2.47.3
_______________________________________________
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-09-25 12:28 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-09-25 12:25 [pve-devel] [PATCH-SERIES v2 qemu-server 0/2] fix #6207: vm status fixes Fiona Ebner
2025-09-25 12:25 ` Fiona Ebner [this message]
2025-09-25 12:25 ` [pve-devel] [PATCH qemu-server 2/2] vm status: also queue query-proxmox-support QMP commands Fiona Ebner
2025-09-25 14:13 ` [pve-devel] applied: [PATCH-SERIES v2 qemu-server 0/2] fix #6207: vm status fixes Thomas Lamprecht
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=20250925122829.70121-2-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.