1
0
Fork 0

chore(smartctl): not perfect, but update layout

This commit is contained in:
Tommy 2025-01-20 06:51:27 +01:00
parent 108042e3fb
commit a4d6471abd
Signed by: tommy
SSH key fingerprint: SHA256:1LWgQT3QPHIT29plS8jjXc3S1FcE/4oGvsx3Efxs6Uc

View file

@ -113,8 +113,8 @@
"overrides": [] "overrides": []
}, },
"gridPos": { "gridPos": {
"h": 8, "h": 9,
"w": 12, "w": 24,
"x": 0, "x": 0,
"y": 1 "y": 1
}, },
@ -173,10 +173,10 @@
"overrides": [] "overrides": []
}, },
"gridPos": { "gridPos": {
"h": 4, "h": 9,
"w": 12, "w": 24,
"x": 12, "x": 0,
"y": 1 "y": 10
}, },
"id": 5, "id": 5,
"options": { "options": {
@ -220,7 +220,7 @@
{ {
"editorMode": "code", "editorMode": "code",
"exemplar": false, "exemplar": false,
"expr": "sum by(device, model_number, firmware_version, serial_number)(\n smartctl_device_smart_status * on(device, instance) group_left(serial_number, firmware_version, serial_number) smartctl_device\n)", "expr": "sum by(serial_number)(\n smartctl_device_smart_status * on(device, instance) group_left(serial_number, firmware_version, serial_number) smartctl_device\n)",
"format": "time_series", "format": "time_series",
"instant": false, "instant": false,
"legendFormat": "{{serial_number}}", "legendFormat": "{{serial_number}}",
@ -269,8 +269,8 @@
"gridPos": { "gridPos": {
"h": 4, "h": 4,
"w": 12, "w": 12,
"x": 12, "x": 0,
"y": 5 "y": 19
}, },
"id": 3, "id": 3,
"options": { "options": {
@ -300,80 +300,6 @@
"title": "Device Critical Warning", "title": "Device Critical Warning",
"type": "status-history" "type": "status-history"
}, },
{
"datasource": {
"type": "prometheus",
"uid": "Prometheus"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "fixed"
},
"decimals": 1,
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
}
]
},
"unit": "s"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 12,
"x": 0,
"y": 9
},
"id": 1,
"options": {
"colorMode": "value",
"graphMode": "none",
"justifyMode": "auto",
"orientation": "vertical",
"percentChangeColorMode": "standard",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "value_and_name",
"wideLayout": true
},
"pluginVersion": "11.4.0",
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "Prometheus"
},
"disableTextWrap": false,
"editorMode": "builder",
"exemplar": false,
"expr": "smartctl_device_power_on_seconds{instance=\"192.168.1.7:9633\"}",
"format": "time_series",
"fullMetaSearch": false,
"includeNullMetadata": true,
"instant": false,
"interval": "",
"legendFormat": "{{device}}",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "Power on Time",
"type": "stat"
},
{ {
"datasource": { "datasource": {
"type": "prometheus", "type": "prometheus",
@ -416,7 +342,7 @@
"h": 4, "h": 4,
"w": 12, "w": 12,
"x": 12, "x": 12,
"y": 9 "y": 19
}, },
"id": 11, "id": 11,
"options": { "options": {
@ -471,6 +397,7 @@
"color": { "color": {
"mode": "fixed" "mode": "fixed"
}, },
"decimals": 1,
"mappings": [], "mappings": [],
"thresholds": { "thresholds": {
"mode": "absolute", "mode": "absolute",
@ -481,7 +408,7 @@
} }
] ]
}, },
"unit": "none" "unit": "s"
}, },
"overrides": [] "overrides": []
}, },
@ -489,14 +416,14 @@
"h": 4, "h": 4,
"w": 12, "w": 12,
"x": 0, "x": 0,
"y": 13 "y": 23
}, },
"id": 8, "id": 1,
"options": { "options": {
"colorMode": "value", "colorMode": "value",
"graphMode": "none", "graphMode": "none",
"justifyMode": "auto", "justifyMode": "auto",
"orientation": "auto", "orientation": "vertical",
"percentChangeColorMode": "standard", "percentChangeColorMode": "standard",
"reduceOptions": { "reduceOptions": {
"calcs": [ "calcs": [
@ -506,7 +433,7 @@
"values": false "values": false
}, },
"showPercentChange": false, "showPercentChange": false,
"textMode": "auto", "textMode": "value_and_name",
"wideLayout": true "wideLayout": true
}, },
"pluginVersion": "11.4.0", "pluginVersion": "11.4.0",
@ -518,17 +445,20 @@
}, },
"disableTextWrap": false, "disableTextWrap": false,
"editorMode": "builder", "editorMode": "builder",
"expr": "smartctl_device_power_cycle_count", "exemplar": false,
"expr": "smartctl_device_power_on_seconds{instance=\"192.168.1.7:9633\"}",
"format": "time_series",
"fullMetaSearch": false, "fullMetaSearch": false,
"includeNullMetadata": true, "includeNullMetadata": true,
"instant": false, "instant": false,
"interval": "",
"legendFormat": "{{device}}", "legendFormat": "{{device}}",
"range": true, "range": true,
"refId": "A", "refId": "A",
"useBackend": false "useBackend": false
} }
], ],
"title": "Power Cycle", "title": "Power on Time",
"type": "stat" "type": "stat"
}, },
{ {
@ -569,7 +499,7 @@
"h": 4, "h": 4,
"w": 12, "w": 12,
"x": 12, "x": 12,
"y": 13 "y": 23
}, },
"id": 9, "id": 9,
"options": { "options": {
@ -614,13 +544,83 @@
"title": "Error Log Count", "title": "Error Log Count",
"type": "stat" "type": "stat"
}, },
{
"datasource": {
"type": "prometheus",
"uid": "Prometheus"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "fixed"
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green",
"value": null
}
]
},
"unit": "none"
},
"overrides": []
},
"gridPos": {
"h": 4,
"w": 12,
"x": 0,
"y": 27
},
"id": 8,
"options": {
"colorMode": "value",
"graphMode": "none",
"justifyMode": "auto",
"orientation": "auto",
"percentChangeColorMode": "standard",
"reduceOptions": {
"calcs": [
"lastNotNull"
],
"fields": "",
"values": false
},
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "11.4.0",
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "Prometheus"
},
"disableTextWrap": false,
"editorMode": "builder",
"expr": "smartctl_device_power_cycle_count",
"fullMetaSearch": false,
"includeNullMetadata": true,
"instant": false,
"legendFormat": "{{device}}",
"range": true,
"refId": "A",
"useBackend": false
}
],
"title": "Power Cycle",
"type": "stat"
},
{ {
"collapsed": false, "collapsed": false,
"gridPos": { "gridPos": {
"h": 1, "h": 1,
"w": 24, "w": 24,
"x": 0, "x": 0,
"y": 17 "y": 31
}, },
"id": 6, "id": 6,
"panels": [], "panels": [],
@ -692,7 +692,7 @@
"h": 8, "h": 8,
"w": 12, "w": 12,
"x": 0, "x": 0,
"y": 18 "y": 32
}, },
"id": 4, "id": 4,
"options": { "options": {
@ -767,7 +767,7 @@
"h": 8, "h": 8,
"w": 12, "w": 12,
"x": 12, "x": 12,
"y": 18 "y": 32
}, },
"id": 2, "id": 2,
"options": { "options": {
@ -833,6 +833,6 @@
"timezone": "", "timezone": "",
"title": "Drive SMART Status", "title": "Drive SMART Status",
"uid": "f8f249a0-be78-41b1-97fe-8d0a92a71b93", "uid": "f8f249a0-be78-41b1-97fe-8d0a92a71b93",
"version": 1, "version": 2,
"weekStart": "" "weekStart": ""
} }