From 4b04f70b6f56af9f451543a08856a44aa6be9ab8 Mon Sep 17 00:00:00 2001 From: Mike Lang Date: Wed, 6 Nov 2019 18:58:12 -0800 Subject: [PATCH] overview dashboard: Add system-level metrics --- monitoring/dashboards/overview.jsonnet | 29 ++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/monitoring/dashboards/overview.jsonnet b/monitoring/dashboards/overview.jsonnet index e83137e..5e64acd 100644 --- a/monitoring/dashboards/overview.jsonnet +++ b/monitoring/dashboards/overview.jsonnet @@ -160,6 +160,35 @@ grafana.dashboard({ }, }, ], + // Third row - process-level health + [ + { + name: "CPU usage", + axis: {min: 0, label: "cores", format: grafana.formats.percent}, + expressions: { + "{{instance}} {{job}}": ||| + sum by (instance, job) ( + rate(process_cpu_seconds_total[2m]) + ) + ||| + }, + }, + { + name: "Memory usage (RSS)", + axis: {min: 0, format: grafana.formats.bytes}, + expressions: { + "{{instance}} {{job}}": "process_resident_memory_bytes", + }, + }, + { + name: "Process restarts", + axis: {min: 0, label: "restarts within last minute"}, + tooltip: "Multiple restarts within 15sec will be missed, and only counted as one.", + expressions: { + "{{instance}} {{job}}": "changes(process_start_time_seconds[1m])", + }, + }, + ], ], },