Skip to content
Snippets Groups Projects
Verified Commit d988ee64 authored by Sheogorath's avatar Sheogorath :european_castle:
Browse files

feat(postgres): Add alert for WAL size

parent e2fb1ce5
No related branches found
No related tags found
No related merge requests found
...@@ -6,6 +6,7 @@ resources: ...@@ -6,6 +6,7 @@ resources:
- repository.yaml - repository.yaml
- release.yaml - release.yaml
- podmonitor.yaml - podmonitor.yaml
- prometheusrules.yaml
configMapGenerator: configMapGenerator:
- name: postgres-system-grafana-dashboards - name: postgres-system-grafana-dashboards
files: files:
......
---
apiVersion: monitoring.coreos.com/v1
kind: PrometheusRule
metadata:
name: postgres-rules
namespace: postgres-system
spec:
groups:
- name: postgres-clusters
rules:
- alert: PostgresHighWALUsage
annotations:
description: The WAL size of the postgres cluster exceeded 1GiB for more than 1 hour. This indicates a problem with either a replica or the WAL archiving process to S3.
summary: The WAL size of the postgres cluster exceeded 1GiB for more than 1 hour.
expr: max by (namespace, cluster_name)(pg_wal_size_bytes) > 2^30
for: 1h
labels:
issue: The WAL size of the postgres cluster exceeded 1GiB for more than 1 hour.
severity: critical
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment