Skip to content

Prometheus Alertmanager Grouping Not Sending Notifications Fix

DodaTech Updated 2026-06-24 3 min read

In this tutorial, you'll learn about Prometheus Alertmanager Grouping Not Sending Notifications Fix. We cover key concepts, practical examples, and best practices.

Your Alertmanager sends a flurry of individual notifications for the same alert — every firing instance triggers a separate Slack message or email instead of being grouped. The group_by configuration is missing, so Alertmanager sends one notification per alert.

The Problem

route:
  receiver: slack-notifications
  group_by: []  # No grouping — every alert fires individually

When 10 pods all trigger HighCPUUsage, Alertmanager sends 10 separate Slack messages. The team is overwhelmed with notifications.

Step-by-Step Fix

1. Configure grouping by relevant labels

route:
  receiver: slack-notifications
  group_by: ['alertname', 'severity']  # Group by alert name and severity
  group_wait: 30s     # Wait 30s before sending (collects alerts)
  group_interval: 5m  # Wait 5m before sending new group updates
  repeat_interval: 4h # Repeat notifications every 4h

2. Route-specific grouping for different receivers

route:
  receiver: default
  group_by: ['alertname', 'severity']
  group_wait: 30s
  group_interval: 5m
  routes:
    # Critical alerts: group by alertname
    - match:
        severity: critical
      receiver: pagerduty-critical
      group_by: ['alertname']
      group_wait: 10s  # Faster delivery for critical
      repeat_interval: 1h

    # Warning alerts: group by service
    - match:
        severity: warning
      receiver: slack-warnings
      group_by: ['alertname', 'service']
      group_wait: 1m
      repeat_interval: 8h

3. Understand notification timing

route:
  group_by: ['alertname']
  group_wait: 30s      # How long to wait before sending first notification
                       # (collects alerts that fire within this window)
  group_interval: 5m   # How long to wait before sending updates
                       # (new alerts in the same group)
  repeat_interval: 4h  # How long to wait before resending
                       # (if alert is still firing)

4. Disable grouping for specific alerts

route:
  receiver: default
  group_by: ['alertname', 'service']
  routes:
    # Watchdog alert — send immediately, no grouping
    - match:
        alertname: Watchdog
      receiver: watchdog
      group_wait: 0s
      group_interval: 1m
      repeat_interval: 1m

Expected output:

Without grouping: 10 notifications (one per pod)
With grouping: 1 notification containing all 10 pods

Notification:
  [FIRING:1] HighCPUUsage (critical)
  Labels: {alertname="HighCPUUsage", severity="critical"}
  Alerts:
    - instance: web-1 (85.3%)
    - instance: web-2 (91.2%)
    - instance: web-3 (88.7%)
    ... (7 more)

Prevention Tips

  • Always set group_by to at least ['alertname']
  • Set group_wait: 30-60s to collect burst of related alerts
  • Set group_interval: 5m to prevent notification storms
  • Use repeat_interval: 4h+ to avoid notification fatigue
  • Override grouping for critical alerts with faster delivery

Common Mistakes with alertmanager group

  1. Non-exhaustive pattern matches that compile with warnings then crash at runtime
  2. Misunderstanding that String is [Char] with poor performance for large text operations
  3. Using foldl instead of foldl' causing stack overflow on large lists

These mistakes appear frequently in real-world PROMETHEUS code. DodaTech's contributors have identified these patterns through analysis of open-source projects and production systems.

Practice Exercise

Write a pure function that safely divides two integers using Maybe, then test it with edge cases like division by zero and negative numbers.

This exercise reinforces the concepts covered in this guide. Try implementing it before checking online solutions.

FAQ

### What's the difference between group_interval and repeat_interval?

group_interval controls how often new alerts from the same group trigger an update notification. repeat_interval controls how often the notification is resent if the alert is still firing. Set repeat_interval higher than group_interval.

How do I group by custom labels?

Use any label in group_by: group_by: ['alertname', 'severity', 'service', 'region']. Alertmanager creates one notification per unique combination of the specified labels. For example, with ['alertname', 'service'], each service gets its own notification per alert.

Can I prevent grouping for a specific alert?

Use a child route with group_by: [...] or group_by: ['alertname'] and short intervals. For the Watchdog alert (synthetic health check), disable grouping entirely with group_wait: 0s and group_interval: 1m.

Built by the developers of DodaTech

Doda Browser, DodaZIP & Durga Antivirus Pro