diff --git a/configs/prometheus/alerts.yml b/configs/prometheus/alerts.yml index 21f7bcd..dd5e69a 100644 --- a/configs/prometheus/alerts.yml +++ b/configs/prometheus/alerts.yml @@ -22,6 +22,17 @@ groups: description: Remaining disk space on {{ $labels.instance }} is {{ $value }}% for more than 15 minutes. + - alert: Postfix mail messages queue is high + expr: postfix_showq_message_age_seconds_count > 20 + for: 1h + labels: + severity: warning + instance: "{{ $labels.instance }}" + annotations: + summary: stalled messages in queue {{ $labels.queue }} of {{ $labels.app }} ({{ $labels.instance }}) + description: Number of messages for queue {{ $labels.queue }} of {{ $labels.app }} ({{ $labels.instance }}) is {{ $value }} for more than 1h. + + # TODO: Revisit, too noisy # - name: docker-alerts # rules: diff --git a/configs/prometheus/config.yml b/configs/prometheus/config.yml index 3f800f3..488cd3b 100644 --- a/configs/prometheus/config.yml +++ b/configs/prometheus/config.yml @@ -101,6 +101,16 @@ scrape_configs: service: postgres env: net + - job_name: pmg-postfix + static_configs: + - targets: + # PMG + - "10.1.0.102:9154" + labels: + app: Proxmox mail gateway + service: postfix + env: prod + - job_name: docker-elasticsearch static_configs: - targets: ["10.1.0.200:9114"]