- Add load average information type into virDomainGetGuestInfo (RHEL-88447) - qemu_agent: Add qemuAgentGetLoadAvg() (RHEL-88447) - qemu: Add support for VIR_DOMAIN_GUEST_INFO_LOAD (RHEL-88447) - virsh: Add support for VIR_DOMAIN_GUEST_INFO_LOAD (RHEL-88447) - qemu_capabilities: Fetch caps for virtio-mem-ccw too (RHEL-87532) - cpu_map: Add avx10* CPU features (RHEL-87796) - cpu_map: Add GraniteRapids-v2 CPU model (RHEL-87796) - cpu_map: Add sha512, sm3, and sm4 CPU features (RHEL-87796) - virsh: Introduce new hypervisor-cpu-models command (RHEL-11435) - qemu: remove nonsensical sanity check in processNetdevStreamDisconnectedEvent() (RHEL-80169) - qemu: make processNetDevStreamDisconnectedEvent() reusable (RHEL-80169) - qemu: respond to NETDEV_VHOST_USER_DISCONNECTED event (RHEL-80169) - qemu: put vhost-user code that's special for passt in a helper function (RHEL-80169) - qemu: make passt+vhostuser reconnect behave identically to passt+user (RHEL-80169) Resolves: RHEL-11435, RHEL-80169, RHEL-87532, RHEL-87796, RHEL-88447
72 lines
2.6 KiB
Diff
72 lines
2.6 KiB
Diff
From 4452c8f1b0a9e953615d15d02ada49c1834c72d5 Mon Sep 17 00:00:00 2001
|
|
Message-ID: <4452c8f1b0a9e953615d15d02ada49c1834c72d5.1747908717.git.jdenemar@redhat.com>
|
|
From: Martin Kletzander <mkletzan@redhat.com>
|
|
Date: Tue, 25 Feb 2025 15:22:35 +0100
|
|
Subject: [PATCH] virsh: Add support for VIR_DOMAIN_GUEST_INFO_LOAD
|
|
|
|
Resolves: https://issues.redhat.com/browse/RHEL-71883
|
|
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
|
|
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
|
|
(cherry picked from commit 71e75ce09203aa2489803426ae368d1693ee925b)
|
|
|
|
https://issues.redhat.com/browse/RHEL-88447
|
|
|
|
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
|
|
---
|
|
docs/manpages/virsh.rst | 8 +++++++-
|
|
tools/virsh-domain.c | 6 ++++++
|
|
2 files changed, 13 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/docs/manpages/virsh.rst b/docs/manpages/virsh.rst
|
|
index aea920b7a7..2bb1313a48 100644
|
|
--- a/docs/manpages/virsh.rst
|
|
+++ b/docs/manpages/virsh.rst
|
|
@@ -2927,7 +2927,7 @@ Success is always reported in this case.
|
|
|
|
You can limit the types of information that are returned by specifying one or
|
|
more flags. Available information types flags are *--user*, *--os*,
|
|
-*--timezone*, *--hostname*, *--filesystem*, *--disk* and *--interface*.
|
|
+*--timezone*, *--hostname*, *--filesystem*, *--disk*, *--interface* and *--load*.
|
|
If an explicitly requested information type is not supported by the guest agent
|
|
at that point, the processes will provide an exit code of 1.
|
|
|
|
@@ -3006,6 +3006,12 @@ returned:
|
|
* ``if.<num>.addr.<num1>.addr`` - the IP address of addr <num1>
|
|
* ``if.<num>.addr.<num1>.prefix`` - the prefix of IP address of addr <num1>
|
|
|
|
+*--load* returns:
|
|
+* ``load.1m`` - average load in guest for last 1 minute
|
|
+* ``load.5m`` - average load in guest for last 5 minutes
|
|
+* ``load.15m`` - average load in guest for last 15 minutes
|
|
+
|
|
+
|
|
guestvcpus
|
|
----------
|
|
|
|
diff --git a/tools/virsh-domain.c b/tools/virsh-domain.c
|
|
index e4923284af..0f30a65fd9 100644
|
|
--- a/tools/virsh-domain.c
|
|
+++ b/tools/virsh-domain.c
|
|
@@ -13066,6 +13066,10 @@ static const vshCmdOptDef opts_guestinfo[] = {
|
|
.type = VSH_OT_BOOL,
|
|
.help = N_("report interface information"),
|
|
},
|
|
+ {.name = "load",
|
|
+ .type = VSH_OT_BOOL,
|
|
+ .help = N_("report load averages information"),
|
|
+ },
|
|
{.name = NULL}
|
|
};
|
|
|
|
@@ -13093,6 +13097,8 @@ cmdGuestInfo(vshControl *ctl, const vshCmd *cmd)
|
|
types |= VIR_DOMAIN_GUEST_INFO_DISKS;
|
|
if (vshCommandOptBool(cmd, "interface"))
|
|
types |= VIR_DOMAIN_GUEST_INFO_INTERFACES;
|
|
+ if (vshCommandOptBool(cmd, "load"))
|
|
+ types |= VIR_DOMAIN_GUEST_INFO_LOAD;
|
|
|
|
if (!(dom = virshCommandOptDomain(ctl, cmd, NULL)))
|
|
return false;
|
|
--
|
|
2.49.0
|