nagios - Grafana:获取 singlestat 的最大值

标签 nagios graphite grafana

我一直在网上搜索这个问题的答案,但我似乎找不到答案或弄清楚。

我是 Grafana 新手,我正在尝试设置一个singestat 仪表。我有

16 servers (HPG6-01 to HPG6-16)

Each server has 8 cores

Each server has Nagios plugin that sends the maximum temperature across all cores. For instance Core 0-8 temperature for HPG6-01 is T = [33,34,55,45,37,38,46,33], Nagios plugin returns Max-Temp = max(T) = 55

Performance data is sent to Shinken, which has a plugin for Graphite.

我可以在 Grafana 中绘制当前的最高温度,这很简单(请参见下面的线图)。但我还希望将 16 台服务器的最高温度最大值显示为单个统计数据。例如,

MT = [34, 56, 60, ...] #the Max-Temp for each of the servers

singlestat = max(MT)

On the right side, we see the maximum temperature across all cores for each server HPG6-01 to HPG6-16. On the right, I want to show the maximum temperature across all servers (the max of max)

单个统计数据的指标如下面的屏幕截图所示:

grafana singlestat metrics

单个统计数据的选项如下所示:

grafana single stat options

关于如何做到这一点有什么想法吗?我尝试了 consolidateBy(max),但收到错误“指标查询返回 16 个系列。单个统计面板需要单个系列。”因为它返回一个序列而不是标量。

最佳答案

我喜欢使用highestMax函数用于此。

highestMax(HPG6*.shinken.Core_Temp.Max-Temp, n)

此函数将仅显示 n 个具有最高值的系列;对于您的用例,我将仅使用 1 来获取所有系列的绝对最大值。

这将显示选定时间范围内具有绝对最大值的系列。要查看最高当前值,请使用该值,

highestCurrent

关于nagios - Grafana:获取 singlestat 的最大值,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40368096/

相关文章:

azure - Grafana for K8S - 配置仪表板访问权限

mysql - 如何将Grafana的Docker容器连接到MySql的Docker容器?

linux - 为什么 nagios check_users 结果不等于 linux "who -q"

graphite - Grafana:如何获得选定时间段的持续时间

Nagios 插件位置

graphite - 如何在现有 Graphite 服务器上使用 asgraphite 写入时间序列数据?

graphite - 如何在 Graphite 中求和,但排除并非所有数据都存在的情况

grafana - 普罗米修斯的简单累积增加

nagios - CHECK_NRPE 无法连接到.... : Connect reset by peer in Nagios NRPE

windows - NSClient++ 未安装在 Windows 中