From: Tom Hughes Date: Wed, 17 May 2023 19:28:09 +0000 (+0100) Subject: Reduce sensitivity of postgres idle transaction alert X-Git-Url: https://git.openstreetmap.org./chef.git/commitdiff_plain/16ae8dd1960a18f6c82973aab884a142a8901f54?hp=6d57f9778a06c121ffafde3b2a2a472acabc6d52 Reduce sensitivity of postgres idle transaction alert --- diff --git a/cookbooks/prometheus/templates/default/alert_rules.yml.erb b/cookbooks/prometheus/templates/default/alert_rules.yml.erb index b53007521..521d2c92b 100644 --- a/cookbooks/prometheus/templates/default/alert_rules.yml.erb +++ b/cookbooks/prometheus/templates/default/alert_rules.yml.erb @@ -526,7 +526,7 @@ groups: annotations: queries: "{{ $value }}" - alert: postgresql idle transactions - expr: sum(pg_process_idle_seconds_count{state="idle in transaction"}) by (instance, server) > sum(pg_process_idle_seconds_bucket{state="idle in transaction",le="120"}) by (instance, server) + expr: sum(pg_process_idle_seconds_count{state="idle in transaction"}) by (instance, server) > sum(pg_process_idle_seconds_bucket{state="idle in transaction",le="300"}) by (instance, server) for: 5m labels: alertgroup: "{{ $labels.instance }}"