This commit is contained in:
m0duspwnens
2020-12-11 11:51:42 -05:00
parent 6eb64227ae
commit 0a77a28e06
2 changed files with 220 additions and 60 deletions

View File

@@ -24,18 +24,36 @@
"fieldConfig": { "fieldConfig": {
"defaults": { "defaults": {
"custom": {}, "custom": {},
"decimals": 2, "unit": "percent",
"mappings": [], "min": 0,
"max": 100,
"thresholds": { "thresholds": {
"mode": "absolute", "mode": "absolute",
"steps": [ "steps": [
{ {
"color": "rgb(255, 255, 255)", "color": "rgba(50, 172, 45, 0.97)",
"value": null "value": null
},
{
"color": "rgba(237, 129, 40, 0.89)",
"value": 60
},
{
"color": "rgba(245, 54, 54, 0.9)",
"value": 80
} }
] ]
}, },
"unit": "s" "mappings": [
{
"id": 0,
"op": "=",
"text": "N/A",
"type": 1,
"value": "null"
}
],
"nullValueMode": "connected"
}, },
"overrides": [] "overrides": []
}, },
@@ -45,23 +63,15 @@
"x": 0, "x": 0,
"y": 0 "y": 0
}, },
"id": 39, "id": 2,
"links": [],
"options": { "options": {
"colorMode": "value", "alertThreshold": true
"graphMode": "none",
"justifyMode": "auto",
"orientation": "auto",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
}
}, },
"pluginVersion": "7.0.5", "pluginVersion": "7.3.4",
"targets": [ "targets": [
{ {
"dsType": "influxdb",
"groupBy": [ "groupBy": [
{ {
"params": [ "params": [
@@ -76,7 +86,7 @@
"type": "fill" "type": "fill"
} }
], ],
"measurement": "system", "measurement": "cpu",
"orderByTime": "ASC", "orderByTime": "ASC",
"policy": "default", "policy": "default",
"refId": "A", "refId": "A",
@@ -85,13 +95,19 @@
[ [
{ {
"params": [ "params": [
"uptime" "usage_idle"
], ],
"type": "field" "type": "field"
}, },
{ {
"params": [], "params": [],
"type": "last" "type": "mean"
},
{
"params": [
"* -1 + 100"
],
"type": "math"
} }
] ]
], ],
@@ -100,14 +116,87 @@
"key": "host", "key": "host",
"operator": "=", "operator": "=",
"value": "{{ SERVERNAME }}" "value": "{{ SERVERNAME }}"
} },
] {
"condition": "AND",
"key": "cpu",
"operator": "=",
"value": "cpu-total"
} }
], ],
"alias": "Usage"
}
],
"title": "{{ SERVERNAME }} - CPU",
"type": "graph",
"cacheTimeout": null,
"renderer": "flot",
"yaxes": [
{
"label": null,
"show": true,
"logBase": 1,
"min": null,
"max": null,
"format": "percent",
"$$hashKey": "object:395"
},
{
"label": null,
"show": false,
"logBase": 1,
"min": null,
"max": null,
"format": "short",
"$$hashKey": "object:396"
}
],
"xaxis": {
"show": true,
"mode": "time",
"name": null,
"values": [],
"buckets": null
},
"yaxis": {
"align": false,
"alignLevel": null
},
"lines": true,
"fill": 1,
"fillGradient": 0,
"linewidth": 1,
"dashes": false,
"hiddenSeries": false,
"dashLength": 10,
"spaceLength": 10,
"points": false,
"pointradius": 2,
"bars": false,
"stack": false,
"percentage": false,
"legend": {
"show": false,
"values": false,
"min": false,
"max": false,
"current": false,
"total": false,
"avg": false
},
"nullPointMode": "connected",
"steppedLine": false,
"tooltip": {
"value_type": "individual",
"shared": true,
"sort": 0
},
"timeFrom": null, "timeFrom": null,
"timeShift": null, "timeShift": null,
"title": "{{ SERVERNAME }} - System Uptime", "aliasColors": {},
"type": "stat" "seriesOverrides": [],
"thresholds": [],
"timeRegions": []
}, },
{ {
"cacheTimeout": null, "cacheTimeout": null,

View File

@@ -20,8 +20,43 @@
"links": [], "links": [],
"panels": [ "panels": [
{ {
"cacheTimeout": null,
"datasource": "InfluxDB", "datasource": "InfluxDB",
"fieldConfig": {
"defaults": {
"custom": {},
"unit": "percent",
"min": 0,
"max": 100,
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "rgba(50, 172, 45, 0.97)",
"value": null
},
{
"color": "rgba(237, 129, 40, 0.89)",
"value": 60
},
{
"color": "rgba(245, 54, 54, 0.9)",
"value": 80
}
]
},
"mappings": [
{
"id": 0,
"op": "=",
"text": "N/A",
"type": 1,
"value": "null"
}
],
"nullValueMode": "connected"
},
"overrides": []
},
"gridPos": { "gridPos": {
"h": 5, "h": 5,
"w": 4, "w": 4,
@@ -31,40 +66,9 @@
"id": 2, "id": 2,
"links": [], "links": [],
"options": { "options": {
"fieldOptions": { "alertThreshold": true
"calcs": [
"lastNotNull"
],
"defaults": {
"mappings": [],
"max": 100,
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
}, },
{ "pluginVersion": "7.3.4",
"color": "orange",
"value": 60
},
{
"color": "red",
"value": 80
}
]
},
"unit": "percent"
},
"overrides": [],
"values": false
},
"orientation": "auto",
"showThresholdLabels": false,
"showThresholdMarkers": true
},
"pluginVersion": "6.6.2",
"targets": [ "targets": [
{ {
"dsType": "influxdb", "dsType": "influxdb",
@@ -119,13 +123,80 @@
"operator": "=", "operator": "=",
"value": "cpu-total" "value": "cpu-total"
} }
] ],
"alias": "Usage"
} }
], ],
"title": "{{ SERVERNAME }} - CPU",
"type": "graph",
"cacheTimeout": null,
"renderer": "flot",
"yaxes": [
{
"label": null,
"show": true,
"logBase": 1,
"min": null,
"max": null,
"format": "percent",
"$$hashKey": "object:395"
},
{
"label": null,
"show": false,
"logBase": 1,
"min": null,
"max": null,
"format": "short",
"$$hashKey": "object:396"
}
],
"xaxis": {
"show": true,
"mode": "time",
"name": null,
"values": [],
"buckets": null
},
"yaxis": {
"align": false,
"alignLevel": null
},
"lines": true,
"fill": 1,
"fillGradient": 0,
"linewidth": 1,
"dashes": false,
"hiddenSeries": false,
"dashLength": 10,
"spaceLength": 10,
"points": false,
"pointradius": 2,
"bars": false,
"stack": false,
"percentage": false,
"legend": {
"show": false,
"values": false,
"min": false,
"max": false,
"current": false,
"total": false,
"avg": false
},
"nullPointMode": "connected",
"steppedLine": false,
"tooltip": {
"value_type": "individual",
"shared": true,
"sort": 0
},
"timeFrom": null, "timeFrom": null,
"timeShift": null, "timeShift": null,
"title": "{{ SERVERNAME }} - CPU", "aliasColors": {},
"type": "gauge" "seriesOverrides": [],
"thresholds": [],
"timeRegions": []
}, },
{ {
"datasource": "InfluxDB", "datasource": "InfluxDB",