[英]How to show aggregated CPU, RAM, Disk I/O usage of a cluster using Prometheus?
I have 3 servers. 我有3台服务器。 I am using Prometheus with Node exporter and for visualizing Prometheus data I am using Grafana.
我正在使用带有节点导出器的Prometheus,并且使用Grafana来可视化Prometheus数据。 The Node Exporter Full (1860) dashboard can only shows CPU, RAM, Disk I/O usages for each server individually.
Node Exporter Full(1860)仪表板只能分别显示每个服务器的CPU,RAM,磁盘I / O使用情况。 I want to get overall usages, for example, I want to get the whole cluster's (sarver1 + sarver2 + sarver3) aggregated CPU, RAM, and Disk I/O usages.
我想要获得总体使用情况,例如,我想要获得整个集群的(sarver1 + sarver2 + sarver3)聚合的CPU,RAM和磁盘I / O使用情况。 What queries should I use to get the total cluster resources utilization?
我应该使用哪些查询来获取群集资源的总利用率?
Suppose you have the following query to get the CPU usage: 假设您具有以下查询来获取CPU使用率:
100 - (avg(irate(node_cpu_seconds_total{instance="server1",mode="idle"}[5m])) * 100)
To get the overall of several servers you need to change the query to the following: 要获得几台服务器的总体信息,您需要将查询更改为以下内容:
100 - (avg(irate(node_cpu_seconds_total{instance=~"server1|server2|server3",mode="idle"}[5m])) * 100)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.