Update example dashboards.

This commit is contained in:
Mark Nellemann 2021-03-31 15:33:50 +02:00
parent 3a6d935d4d
commit b1d70e4816
6 changed files with 2021 additions and 999 deletions

View file

@ -61,7 +61,7 @@
"gnetId": null,
"graphTooltip": 0,
"id": null,
"iteration": 1616701412999,
"iteration": 1617197417499,
"links": [],
"panels": [
{
@ -361,7 +361,7 @@
"overrides": []
},
"gridPos": {
"h": 10,
"h": 7,
"w": 7,
"x": 0,
"y": 10
@ -461,7 +461,7 @@
"fill": 1,
"fillGradient": 1,
"gridPos": {
"h": 10,
"h": 7,
"w": 17,
"x": 7,
"y": 10
@ -652,7 +652,7 @@
}
}
],
"refresh": "30s",
"refresh": "1m",
"schemaVersion": 27,
"style": "dark",
"tags": [
@ -687,14 +687,12 @@
]
},
"time": {
"from": "now-3h",
"from": "now-2d",
"to": "now-1m"
},
"timepicker": {
"nowDelay": "1m",
"refresh_intervals": [
"5s",
"10s",
"30s",
"1m",
"5m",
@ -706,7 +704,7 @@
]
},
"timezone": "",
"title": "IBM Power - HMC Managed Systems - Energy",
"title": "IBM Power - HMCi - System Energy",
"uid": "oHcrgD1Mk",
"version": 18
"version": 20
}

View file

@ -60,7 +60,7 @@
"gnetId": 1465,
"graphTooltip": 0,
"id": null,
"iteration": 1616701472507,
"iteration": 1617197428882,
"links": [],
"panels": [
{
@ -74,8 +74,8 @@
},
"id": 20,
"panels": [],
"repeat": "ManagedSystem",
"title": "$ServerName Resource Overview",
"repeat": "ServerName",
"title": "Processors - $ServerName",
"type": "row"
},
{
@ -667,16 +667,20 @@
"yBucketSize": null
},
{
"collapsed": true,
"collapsed": false,
"datasource": "${DS_HMCI}",
"gridPos": {
"h": 1,
"w": 24,
"x": 0,
"y": 16
"y": 32
},
"id": 22,
"panels": [
"panels": [],
"repeat": "ServerName",
"title": "Network & Storage I/O - $ServerName ",
"type": "row"
},
{
"aliasColors": {},
"bars": false,
@ -698,9 +702,9 @@
"grid": {},
"gridPos": {
"h": 8,
"w": 24,
"w": 12,
"x": 0,
"y": 17
"y": 33
},
"hiddenSeries": false,
"id": 16,
@ -752,6 +756,12 @@
],
"type": "tag"
},
{
"params": [
"servername"
],
"type": "tag"
},
{
"params": [
"null"
@ -854,9 +864,9 @@
"grid": {},
"gridPos": {
"h": 8,
"w": 24,
"x": 0,
"y": 25
"w": 12,
"x": 12,
"y": 33
},
"hiddenSeries": false,
"id": 11,
@ -874,7 +884,7 @@
"values": true
},
"lines": true,
"linewidth": 2,
"linewidth": 1,
"links": [],
"mode": "",
"nullPointMode": "connected",
@ -888,12 +898,12 @@
"renderer": "flot",
"seriesOverrides": [],
"spaceLength": 10,
"stack": true,
"stack": false,
"steppedLine": false,
"style": {},
"targets": [
{
"alias": "$tag_location",
"alias": "VLAN $tag_vlanId recv",
"dsType": "influxdb",
"groupBy": [
{
@ -904,7 +914,13 @@
},
{
"params": [
"location"
"servername"
],
"type": "tag"
},
{
"params": [
"vlanId"
],
"type": "tag"
},
@ -916,7 +932,7 @@
}
],
"hide": false,
"measurement": "vios_network_shared",
"measurement": "lpar_net_virtual",
"orderByTime": "ASC",
"policy": "default",
"refId": "A",
@ -925,7 +941,7 @@
[
{
"params": [
"transferredBytes"
"receivedBytes"
],
"type": "field"
},
@ -942,18 +958,81 @@
"value": "/^$ServerName$/"
}
]
},
{
"alias": "VLAN $tag_vlanId sent",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$interval"
],
"type": "time"
},
{
"params": [
"servername"
],
"type": "tag"
},
{
"params": [
"vlanId"
],
"type": "tag"
},
{
"params": [
"null"
],
"type": "fill"
}
],
"hide": false,
"measurement": "lpar_net_virtual",
"orderByTime": "ASC",
"policy": "default",
"refId": "B",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"sentBytes"
],
"type": "field"
},
{
"params": [],
"type": "mean"
},
{
"params": [
"*-1"
],
"type": "math"
}
]
],
"tags": [
{
"key": "servername",
"operator": "=~",
"value": "/^$ServerName$/"
}
]
}
],
"thresholds": [],
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "$ServerName - Shared Adapters",
"title": "$ServerName - Network",
"tooltip": {
"msResolution": false,
"shared": true,
"sort": 2,
"value_type": "individual"
"value_type": "cumulative"
},
"type": "graph",
"xaxis": {
@ -987,11 +1066,6 @@
"align": false,
"alignLevel": null
}
}
],
"repeat": "ManagedSystem",
"title": "$ServerName Network",
"type": "row"
},
{
"collapsed": false,
@ -1000,12 +1074,12 @@
"h": 1,
"w": 24,
"x": 0,
"y": 17
"y": 82
},
"id": 21,
"panels": [],
"repeat": "ManagedSystem",
"title": "$ServerName By Partition",
"repeat": "ServerName",
"title": "Partition Usage - $ServerName",
"type": "row"
},
{
@ -1032,7 +1106,7 @@
"h": 7,
"w": 12,
"x": 0,
"y": 18
"y": 83
},
"hiddenSeries": false,
"id": 12,
@ -1085,6 +1159,12 @@
],
"type": "tag"
},
{
"params": [
"servername"
],
"type": "tag"
},
{
"params": [
"null"
@ -1122,7 +1202,7 @@
"condition": "AND",
"key": "lparname",
"operator": "=~",
"value": "/^$LparName$/"
"value": "/^$LPAR$/"
}
]
}
@ -1199,7 +1279,7 @@
"h": 7,
"w": 12,
"x": 12,
"y": 18
"y": 83
},
"id": 23,
"links": [],
@ -1277,7 +1357,7 @@
"condition": "AND",
"key": "lparname",
"operator": "=~",
"value": "/^$LparName$/"
"value": "/^$LPAR$/"
}
]
}
@ -1288,7 +1368,7 @@
"type": "bargauge"
}
],
"refresh": "30s",
"refresh": "1m",
"schemaVersion": 27,
"style": "dark",
"tags": [
@ -1336,7 +1416,7 @@
"label": "Partition",
"multi": true,
"multiFormat": "regex values",
"name": "LparName",
"name": "LPAR",
"options": [],
"query": "SHOW TAG VALUES FROM \"lpar_processor\" WITH KEY = \"lparname\" WHERE servername =~ /$ServerName/",
"refresh": 1,
@ -1353,14 +1433,13 @@
]
},
"time": {
"from": "now-3h",
"from": "now-2d",
"now": false,
"to": "now-1m"
},
"timepicker": {
"nowDelay": "1m",
"refresh_intervals": [
"10s",
"30s",
"1m",
"5m",
@ -1383,7 +1462,7 @@
]
},
"timezone": "browser",
"title": "IBM Power - HMC Managed Systems - Resources",
"title": "IBM Power - HMCi - System Resources",
"uid": "ClJhHPIGz",
"version": 19
"version": 26
}

View file

@ -33,6 +33,12 @@
"id": "influxdb",
"name": "InfluxDB",
"version": "1.0.0"
},
{
"type": "panel",
"id": "table",
"name": "Table",
"version": ""
}
],
"annotations": {
@ -54,9 +60,148 @@
"gnetId": 1465,
"graphTooltip": 0,
"id": null,
"iteration": 1616701495725,
"iteration": 1617197467456,
"links": [],
"panels": [
{
"datasource": "${DS_HMCI}",
"description": "",
"fieldConfig": {
"defaults": {
"color": {
"mode": "continuous-RdYlGr"
},
"custom": {
"align": "center",
"displayMode": "auto",
"filterable": true
},
"mappings": [],
"thresholds": {
"mode": "percentage",
"steps": [
{
"color": "green",
"value": null
}
]
},
"unit": "none"
},
"overrides": [
{
"matcher": {
"id": "byName",
"options": "lparname"
},
"properties": [
{
"id": "custom.width",
"value": 256
}
]
},
{
"matcher": {
"id": "byName",
"options": "affinityScore"
},
"properties": [
{
"id": "color",
"value": {
"mode": "thresholds"
}
},
{
"id": "unit",
"value": "percent"
}
]
}
]
},
"gridPos": {
"h": 5,
"w": 24,
"x": 0,
"y": 0
},
"id": 21,
"options": {
"showHeader": true,
"sortBy": []
},
"pluginVersion": "7.4.2",
"targets": [
{
"alias": "Read",
"groupBy": [
{
"params": [
"viosname"
],
"type": "tag"
}
],
"measurement": "vios_details",
"orderByTime": "ASC",
"policy": "default",
"query": "SELECT last(\"id\") AS \"id\", \"type\", \"osType\", \"state\", \"affinityScore\" FROM \"lpar_details\" WHERE (\"lparname\" =~ /^$LPAR$/) AND $timeFilter GROUP BY \"lparname\"",
"queryType": "randomWalk",
"rawQuery": false,
"refId": "A",
"resultFormat": "table",
"select": [
[
{
"params": [
"viosid"
],
"type": "field"
},
{
"params": [],
"type": "last"
},
{
"params": [
"id"
],
"type": "alias"
}
],
[
{
"params": [
"viosstate"
],
"type": "field"
}
],
[
{
"params": [
"affinityScore"
],
"type": "field"
}
]
],
"tags": [
{
"key": "viosname",
"operator": "=~",
"value": "/^$ViosName$/"
}
]
}
],
"timeFrom": null,
"timeShift": null,
"title": "",
"type": "table"
},
{
"datasource": "${DS_HMCI}",
"description": "",
@ -83,10 +228,10 @@
"overrides": []
},
"gridPos": {
"h": 10,
"w": 11,
"h": 9,
"w": 7,
"x": 0,
"y": 0
"y": 5
},
"id": 16,
"links": [],
@ -105,7 +250,7 @@
"pluginVersion": "7.4.2",
"targets": [
{
"alias": "$tag_vios",
"alias": "$tag_viosname",
"dsType": "influxdb",
"groupBy": [
{
@ -164,7 +309,7 @@
],
"timeFrom": null,
"timeShift": null,
"title": "$ServerName - $ViosName Memory",
"title": " Memory - $ServerName - $ViosName",
"type": "gauge"
},
{
@ -188,10 +333,10 @@
"fillGradient": 2,
"grid": {},
"gridPos": {
"h": 10,
"w": 13,
"x": 11,
"y": 0
"h": 9,
"w": 17,
"x": 7,
"y": 5
},
"hiddenSeries": false,
"id": 19,
@ -241,12 +386,6 @@
],
"type": "tag"
},
{
"params": [
"name"
],
"type": "tag"
},
{
"params": [
"null"
@ -293,7 +432,7 @@
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "$ServerName - $ViosName - Processors",
"title": "Processors - $ServerName - $ViosName",
"tooltip": {
"msResolution": false,
"shared": true,
@ -350,14 +489,14 @@
},
"overrides": []
},
"fill": 2,
"fillGradient": 2,
"fill": 1,
"fillGradient": 1,
"grid": {},
"gridPos": {
"h": 10,
"h": 9,
"w": 24,
"x": 0,
"y": 10
"y": 14
},
"hiddenSeries": false,
"id": 18,
@ -373,7 +512,7 @@
"values": true
},
"lines": true,
"linewidth": 2,
"linewidth": 1,
"links": [],
"mode": "",
"nullPointMode": "connected",
@ -392,7 +531,7 @@
"style": {},
"targets": [
{
"alias": "$tag_viosname: $tag_id ($tag_location)",
"alias": "$tag_viosname: $tag_id ($tag_location) read",
"dsType": "influxdb",
"groupBy": [
{
@ -436,7 +575,7 @@
[
{
"params": [
"transmittedBytes"
"readBytes"
],
"type": "field"
},
@ -459,13 +598,88 @@
"value": "/^$ViosName$/"
}
]
},
{
"alias": "$tag_viosname: $tag_id ($tag_location) write",
"dsType": "influxdb",
"groupBy": [
{
"params": [
"$interval"
],
"type": "time"
},
{
"params": [
"viosname"
],
"type": "tag"
},
{
"params": [
"location"
],
"type": "tag"
},
{
"params": [
"id"
],
"type": "tag"
},
{
"params": [
"null"
],
"type": "fill"
}
],
"hide": false,
"measurement": "vios_storage_FC",
"orderByTime": "ASC",
"policy": "default",
"refId": "B",
"resultFormat": "time_series",
"select": [
[
{
"params": [
"writeBytes"
],
"type": "field"
},
{
"params": [],
"type": "mean"
},
{
"params": [
"*-1"
],
"type": "math"
}
]
],
"tags": [
{
"key": "servername",
"operator": "=~",
"value": "/^$ServerName$/"
},
{
"condition": "AND",
"key": "viosname",
"operator": "=~",
"value": "/^$ViosName$/"
}
]
}
],
"thresholds": [],
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "$ServerName - $ViosName - Fiber Channel Adapters",
"title": "Fiber Channel Adapters - $ServerName - $ViosName",
"tooltip": {
"msResolution": false,
"shared": true,
@ -526,10 +740,10 @@
"fillGradient": 1,
"grid": {},
"gridPos": {
"h": 11,
"h": 9,
"w": 24,
"x": 0,
"y": 20
"y": 23
},
"hiddenSeries": false,
"id": 17,
@ -545,7 +759,7 @@
"values": true
},
"lines": true,
"linewidth": 2,
"linewidth": 1,
"links": [],
"mode": "",
"nullPointMode": "connected",
@ -739,7 +953,7 @@
"timeFrom": null,
"timeRegions": [],
"timeShift": null,
"title": "$ServerName - $ViosName - Network",
"title": "Network - $ServerName - $ViosName",
"tooltip": {
"msResolution": false,
"shared": true,
@ -780,7 +994,7 @@
}
}
],
"refresh": "30s",
"refresh": "1m",
"schemaVersion": 27,
"style": "dark",
"tags": [
@ -847,14 +1061,13 @@
]
},
"time": {
"from": "now-3h",
"from": "now-2d",
"now": false,
"to": "now-1m"
},
"timepicker": {
"nowDelay": "1m",
"refresh_intervals": [
"10s",
"30s",
"1m",
"5m",
@ -877,7 +1090,7 @@
]
},
"timezone": "browser",
"title": "IBM Power - HMC Managed Systems - Virtual I/O Servers",
"title": "IBM Power - HMCi - Virtual I/O Servers",
"uid": "DDNEv5vGz",
"version": 11
"version": 18
}

View file

@ -70,13 +70,13 @@ class HmcInstance implements Runnable {
do {
Instant instantStart = Instant.now();
try {
getMetricsForEnergy();
getMetricsForSystems();
getMetricsForPartitions();
getMetricsForEnergy();
writeMetricsForSystemEnergy();
writeMetricsForManagedSystems();
writeMetricsForLogicalPartitions();
writeMetricsForSystemEnergy();
influxClient.writeBatchPoints();
// Refresh

View file

@ -214,7 +214,7 @@ public class HmcRestClient {
try {
Document doc = Jsoup.parse(responseBody);
Elements logicalPartitions = doc.select("LogicalPartition|LogicalPartition"); // doc.select("img[src$=.png]");
Elements logicalPartitions = doc.select("LogicalPartition|LogicalPartition");
for(Element el : logicalPartitions) {
LogicalPartition logicalPartition = new LogicalPartition(
el.select("PartitionUUID").text(),
@ -409,7 +409,7 @@ public class HmcRestClient {
*/
private String sendGetRequest(URL url) throws Exception {
log.trace("getResponse() - " + url.toString());
log.trace("getResponse() - URL: " + url.toString());
if(authToken == null) {
return null;
}
@ -451,7 +451,7 @@ public class HmcRestClient {
*/
public String sendPostRequest(URL url, String payload) throws Exception {
log.trace("sendPostRequest() - " + url.toString());
log.trace("sendPostRequest() - URL: " + url.toString());
if(authToken == null) {
return null;
}