From 4563731171e71acd84c391d0e6334c9647d65349 Mon Sep 17 00:00:00 2001 From: Charles Korn Date: Wed, 3 May 2023 15:18:49 +1000 Subject: [PATCH] Hack: replace `container_cpu_usage_seconds_total` with `process_cpu_seconds_total` in dashboard panels --- .../dashboards/mimir-alertmanager-resources.json | 4 ++-- .../dashboards/mimir-compactor-resources.json | 4 ++-- .../dashboards/mimir-overview-resources.json | 8 ++++---- .../dashboards/mimir-reads-resources.json | 16 ++++++++-------- .../mimir-remote-ruler-reads-resources.json | 8 ++++---- .../dashboards/mimir-writes-resources.json | 8 ++++---- 6 files changed, 24 insertions(+), 24 deletions(-) diff --git a/operations/mimir-mixin-compiled/dashboards/mimir-alertmanager-resources.json b/operations/mimir-mixin-compiled/dashboards/mimir-alertmanager-resources.json index 8b0a16337d8..2be212f0a3b 100644 --- a/operations/mimir-mixin-compiled/dashboards/mimir-alertmanager-resources.json +++ b/operations/mimir-mixin-compiled/dashboards/mimir-alertmanager-resources.json @@ -81,7 +81,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"alertmanager\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"alertmanager\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -845,4 +845,4 @@ "title": "Mimir / Alertmanager resources", "uid": "a6883fb22799ac74479c7db872451092", "version": 0 - } \ No newline at end of file + } diff --git a/operations/mimir-mixin-compiled/dashboards/mimir-compactor-resources.json b/operations/mimir-mixin-compiled/dashboards/mimir-compactor-resources.json index 063d9827176..ca73908c277 100644 --- a/operations/mimir-mixin-compiled/dashboards/mimir-compactor-resources.json +++ b/operations/mimir-mixin-compiled/dashboards/mimir-compactor-resources.json @@ -81,7 +81,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"compactor\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"compactor\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -952,4 +952,4 @@ "title": "Mimir / Compactor resources", "uid": "09a5c49e9cdb2f2b24c6d184574a07fd", "version": 0 - } \ No newline at end of file + } diff --git a/operations/mimir-mixin-compiled/dashboards/mimir-overview-resources.json b/operations/mimir-mixin-compiled/dashboards/mimir-overview-resources.json index 07a04eb6cd4..c38caae706d 100644 --- a/operations/mimir-mixin-compiled/dashboards/mimir-overview-resources.json +++ b/operations/mimir-mixin-compiled/dashboards/mimir-overview-resources.json @@ -66,7 +66,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"distributor|ingester|mimir-write\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"distributor|ingester|mimir-write\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -544,7 +544,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-frontend|querier|ruler-query-frontend|ruler-querier|mimir-read\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-frontend|querier|ruler-query-frontend|ruler-querier|mimir-read\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -782,7 +782,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-scheduler|ruler-query-scheduler|ruler|store-gateway|compactor|alertmanager|overrides-exporter|mimir-backend\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-scheduler|ruler-query-scheduler|ruler|store-gateway|compactor|alertmanager|overrides-exporter|mimir-backend\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -1327,4 +1327,4 @@ "title": "Mimir / Overview resources", "uid": "a9b92d3c4d1af325d872a9e9a7083d71", "version": 0 - } \ No newline at end of file + } diff --git a/operations/mimir-mixin-compiled/dashboards/mimir-reads-resources.json b/operations/mimir-mixin-compiled/dashboards/mimir-reads-resources.json index 60c6232dcae..4ef4fad50aa 100644 --- a/operations/mimir-mixin-compiled/dashboards/mimir-reads-resources.json +++ b/operations/mimir-mixin-compiled/dashboards/mimir-reads-resources.json @@ -66,7 +66,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-frontend|querier|ruler-query-frontend|ruler-querier|mimir-read\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-frontend|querier|ruler-query-frontend|ruler-querier|mimir-read\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -319,7 +319,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-frontend\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-frontend\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -615,7 +615,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-scheduler\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"query-scheduler\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -911,7 +911,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"querier\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"querier\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -1207,7 +1207,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ingester\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ingester\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -1696,7 +1696,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -2004,7 +2004,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"store-gateway\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"store-gateway\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -2709,4 +2709,4 @@ "title": "Mimir / Reads resources", "uid": "cc86fd5aa9301c6528986572ad974db9", "version": 0 - } \ No newline at end of file + } diff --git a/operations/mimir-mixin-compiled/dashboards/mimir-remote-ruler-reads-resources.json b/operations/mimir-mixin-compiled/dashboards/mimir-remote-ruler-reads-resources.json index c89308fe64f..4d53780ef91 100644 --- a/operations/mimir-mixin-compiled/dashboards/mimir-remote-ruler-reads-resources.json +++ b/operations/mimir-mixin-compiled/dashboards/mimir-remote-ruler-reads-resources.json @@ -81,7 +81,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler-query-frontend\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler-query-frontend\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -377,7 +377,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler-query-scheduler\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler-query-scheduler\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -673,7 +673,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler-querier\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ruler-querier\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -1021,4 +1021,4 @@ "title": "Mimir / Remote ruler reads resources", "uid": "1940f6ef765a506a171faa2056c956c3", "version": 0 - } \ No newline at end of file + } diff --git a/operations/mimir-mixin-compiled/dashboards/mimir-writes-resources.json b/operations/mimir-mixin-compiled/dashboards/mimir-writes-resources.json index 2ebc63800b9..ae6615f17ff 100644 --- a/operations/mimir-mixin-compiled/dashboards/mimir-writes-resources.json +++ b/operations/mimir-mixin-compiled/dashboards/mimir-writes-resources.json @@ -66,7 +66,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"distributor|ingester|mimir-write\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"distributor|ingester|mimir-write\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -319,7 +319,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"distributor\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"distributor\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -689,7 +689,7 @@ "steppedLine": false, "targets": [ { - "expr": "sum by(pod) (rate(container_cpu_usage_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ingester\"}[$__rate_interval]))", + "expr": "sum by(pod) (rate(process_cpu_seconds_total{cluster=~\"$cluster\", namespace=~\"$namespace\",container=~\"ingester\"}[$__rate_interval]))", "format": "time_series", "intervalFactor": 2, "legendFormat": "{{pod}}", @@ -1394,4 +1394,4 @@ "title": "Mimir / Writes resources", "uid": "bc9160e50b52e89e0e49c840fea3d379", "version": 0 - } \ No newline at end of file + }