[pve-devel] [PATCH pve-manager] pvestatd: stream host pressure counters
Alexandre Derumier
aderumier at odiso.com
Tue Oct 6 13:58:50 CEST 2020
Signed-off-by: Alexandre Derumier <aderumier at odiso.com>
---
PVE/Service/pvestatd.pm | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/PVE/Service/pvestatd.pm b/PVE/Service/pvestatd.pm
index 5e533ca3..238c36ae 100755
--- a/PVE/Service/pvestatd.pm
+++ b/PVE/Service/pvestatd.pm
@@ -161,12 +161,16 @@ sub update_node_status {
);
PVE::Cluster::broadcast_rrd("pve2-node/$nodename", $data);
+ my $pressure = PVE::ProcFSTools::read_pressure();
+ PVE::Cluster::broadcast_node_kv("pressure", encode_json($pressure));
+
my $node_metric = {
uptime => $uptime,
cpustat => $stat,
memory => $meminfo,
blockstat => $dinfo,
nics => $netdev,
+ pressure => $pressure,
};
$node_metric->{cpustat}->@{qw(avg1 avg5 avg15)} = ($avg1, $avg5, $avg15);
$node_metric->{cpustat}->{cpus} = $maxcpu;
--
2.20.1
More information about the pve-devel
mailing list