0
이것이 가능한지 확실하지 않지만 우리는 단일판 패널을 사용하여 grafana에서 전반적인 상태 대시 보드를 만들려고합니다. 우리는 템플릿을 사용하여 호스트를 두 개의 사이트로 그룹화하고 Icinga2에서 hostalive의 패킷 손실 값을 사용했습니다. 우리는 단일 패널에 호스트의 비율을 보여주고 싶지만 때로는 null 값을 얻습니다. 여기에 우리의 패널에서 JSON의 : 호스트에 대한Grafana 상태 보드
{
"id": 2,
"title": "Host Group 2",
"span": 6,
"type": "singlestat",
"targets": [
{
"target": "icinga2.$group1.host.hostalive.perfdata.pl.value",
"refId": "A",
"hide": true
},
{
"target": "keepLastValue(averageSeries(#A))",
"refId": "B",
"textEditor": true,
"targetFull": "keepLastValue(averageSeries(icinga2.$group1.host.hostalive.perfdata.pl.value), 10000)"
}
],
"links": [],
"datasource": null,
"maxDataPoints": "",
"interval": null,
"cacheTimeout": null,
"format": "percent",
"prefix": "",
"postfix": "",
"nullText": null,
"valueMaps": [
{
"value": "null",
"op": "=",
"text": "N/A"
}
],
"mappingTypes": [
{
"name": "value to text",
"value": 1
},
{
"name": "range to text",
"value": 2
}
],
"rangeMaps": [
{
"from": "null",
"to": "null",
"text": "N/A"
}
],
"mappingType": 1,
"nullPointMode": "connected",
"valueName": "current",
"prefixFontSize": "50%",
"valueFontSize": "80%",
"postfixFontSize": "50%",
"thresholds": "50, 100",
"colorBackground": true,
"colorValue": false,
"colors": [
"rgba(50, 172, 45, 0.97)",
"rgba(237, 129, 40, 0.89)",
"rgba(245, 54, 54, 0.9)"
],
"sparkline": {
"show": false,
"full": false,
"lineColor": "rgb(31, 120, 193)",
"fillColor": "rgba(31, 118, 189, 0.18)"
},
"gauge": {
"show": false,
"minValue": 0,
"maxValue": 100,
"thresholdMarkers": true,
"thresholdLabels": false
}
}
폴링 간격마다 10 분의 grafana 보드 범위는 "오늘"이고 초마다 새로 고침 설정합니다.