Skip to content

Commit

Permalink
Fix node exporter metrics (after deployment restarts) and add panel f…
Browse files Browse the repository at this point in the history
…or new load service
  • Loading branch information
adeveloper-wq committed Jun 24, 2024
1 parent 5556766 commit 6d98137
Showing 1 changed file with 118 additions and 104 deletions.
222 changes: 118 additions & 104 deletions provisioning/dashboards/home.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"id": 5,
"id": 2,
"links": [],
"liveNow": false,
"panels": [
Expand Down Expand Up @@ -105,7 +105,7 @@
},
"editorMode": "code",
"exemplar": false,
"expr": "(1 - avg by(instance) (rate(node_cpu_seconds_total{mode=\"idle\"}[10m]))) * 100\n * on(instance) group_left(node_id, node_name) node_meta\n",
"expr": "sum((1 - avg by(instance) (rate(node_cpu_seconds_total{mode=\"idle\"}[10m]))) * 100\n * on(instance) group_left(node_id, node_name) node_meta)by (node_id, node_name)\n",
"hide": false,
"instant": false,
"legendFormat": "{{node_name}}",
Expand Down Expand Up @@ -183,7 +183,7 @@
},
"editorMode": "code",
"exemplar": false,
"expr": "(\n ((node_filesystem_avail_bytes{mountpoint=\"/\"} * on(instance) group_left(node_id, node_name) node_meta)) / 1000000000\n)",
"expr": "(\n (sum(node_filesystem_avail_bytes{mountpoint=\"/\"} * on(instance) group_left(node_id, node_name) node_meta)by(node_id,node_name)) / 1000000000\n)",
"format": "time_series",
"instant": false,
"legendFormat": "{{node_name}} {{mountpoint}}",
Expand Down Expand Up @@ -2137,7 +2137,7 @@
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "line",
"fillOpacity": 50,
"fillOpacity": 0,
"gradientMode": "none",
"hideFrom": {
"legend": false,
Expand Down Expand Up @@ -2166,31 +2166,126 @@
"mode": "absolute",
"steps": [
{
"color": "green"
"color": "green",
"value": null
},
{
"color": "red",
"value": 80
}
]
},
"unit": "percent",
"unitScale": true
},
"overrides": []
"overrides": [
{
"matcher": {
"id": "byName",
"options": "Recommend Other Backend"
},
"properties": [
{
"id": "unit",
"value": "none"
},
{
"id": "max",
"value": 1
},
{
"id": "min",
"value": 0
},
{
"id": "custom.fillOpacity",
"value": 50
},
{
"id": "decimals",
"value": 0
},
{
"id": "mappings",
"value": [
{
"options": {
"0": {
"index": 1,
"text": "Off"
},
"1": {
"index": 0,
"text": "On"
}
},
"type": "value"
}
]
}
]
},
{
"matcher": {
"id": "byName",
"options": "Show Warning"
},
"properties": [
{
"id": "unit",
"value": "none"
},
{
"id": "min",
"value": 0
},
{
"id": "max",
"value": 1
},
{
"id": "custom.fillOpacity",
"value": 50
},
{
"id": "decimals",
"value": 0
},
{
"id": "mappings",
"value": [
{
"options": {
"0": {
"index": 0,
"text": "Off"
},
"1": {
"index": 1,
"text": "On"
}
},
"type": "value"
}
]
}
]
}
]
},
"gridPos": {
"h": 8,
"w": 12,
"w": 24,
"x": 0,
"y": 73
},
"id": 68,
"id": 80,
"options": {
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": false
"showLegend": true
},
"tooltip": {
"mode": "single",
Expand All @@ -2204,8 +2299,8 @@
"uid": "PBFA97CFB590B2093"
},
"editorMode": "code",
"expr": "last_status_app_starts",
"legendFormat": "# App Starts (per Bucket)",
"expr": "load_pct",
"legendFormat": "{{node_type}}",
"range": true,
"refId": "A"
},
Expand All @@ -2215,109 +2310,28 @@
"uid": "PBFA97CFB590B2093"
},
"editorMode": "code",
"expr": "last_status_past_buckets_avg_cpm",
"expr": "recommend_other_backend",
"hide": false,
"legendFormat": "# App Starts (past three weeks)",
"instant": false,
"legendFormat": "Recommend Other Backend",
"range": true,
"refId": "B"
}
],
"title": "# App Starts (bucket-wise)",
"type": "timeseries"
},
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
},
"fieldConfig": {
"defaults": {
"color": {
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
"axisPlacement": "auto",
"barAlignment": 0,
"drawStyle": "bars",
"fillOpacity": 50,
"gradientMode": "none",
"hideFrom": {
"legend": false,
"tooltip": false,
"viz": false
},
"insertNulls": false,
"lineInterpolation": "linear",
"lineWidth": 1,
"pointSize": 5,
"scaleDistribution": {
"type": "linear"
},
"showPoints": "never",
"spanNulls": false,
"stacking": {
"group": "A",
"mode": "none"
},
"thresholdsStyle": {
"mode": "off"
}
},
"mappings": [],
"thresholds": {
"mode": "absolute",
"steps": [
{
"color": "green"
},
{
"color": "red",
"value": 80
}
]
},
"unit": "bool_on_off",
"unitScale": true
},
"overrides": []
},
"gridPos": {
"h": 8,
"w": 12,
"x": 12,
"y": 73
},
"id": 71,
"options": {
"legend": {
"calcs": [],
"displayMode": "list",
"placement": "bottom",
"showLegend": false
},
"tooltip": {
"mode": "single",
"sort": "none"
}
},
"targets": [
{
"datasource": {
"type": "prometheus",
"uid": "PBFA97CFB590B2093"
},
"editorMode": "code",
"expr": "last_status_warning",
"legendFormat": "Load Warning",
"expr": "warning",
"hide": false,
"instant": false,
"legendFormat": "Show Warning",
"range": true,
"refId": "A"
"refId": "C"
}
],
"title": "Load Warning active",
"title": "CPU Load per Node Type",
"type": "timeseries"
}
],
Expand All @@ -2328,14 +2342,14 @@
"list": []
},
"time": {
"from": "now-15m",
"from": "now-30d",
"to": "now"
},
"timeRangeUpdatedDuringEditOrView": false,
"timepicker": {},
"timezone": "",
"title": "Priobike",
"uid": "sdmbOcJnz",
"version": 2,
"version": 22,
"weekStart": ""
}
}

0 comments on commit 6d98137

Please sign in to comment.