fix(grafana): NUT dashboard instance variable ignores stale series
The variable used label_values() which lists all instances across full retention, alphabetically sorting and auto-selecting the dead 127.0.0.1:9199 (relabeled to 'eaton' ~31h ago). Its stale series has no samples in the visible window so every panel rendered empty. Replace with query_result(count by (instance) (...)) which only surfaces live targets.
This commit is contained in:
@@ -16,7 +16,8 @@
|
||||
"label": "UPS",
|
||||
"type": "query",
|
||||
"datasource": { "type": "prometheus", "uid": "prometheus" },
|
||||
"query": { "query": "label_values(network_ups_tools_device_info, instance)", "refId": "A" },
|
||||
"query": { "query": "query_result(count by (instance) (network_ups_tools_device_info))", "refId": "A" },
|
||||
"regex": "/.*instance=\"([^\"]+)\".*/",
|
||||
"refresh": 2,
|
||||
"multi": false,
|
||||
"includeAll": false,
|
||||
|
||||
Reference in New Issue
Block a user