Mixed firing and resolved events in the same alert email

172 views
Skip to first unread message

xud...@gmail.com

unread,
May 16, 2019, 2:04:04 AM5/16/19
to Prometheus Users
Hi, I configured alert manager as follow:

route:
    receiver: alert-receiver
    group_wait: 30s
    group_interval: 5m
    repeat_interval: 24h
    group_by: [alertname]
receivers:
- name: "alert-receiver"
  email_configs:
    - to: x...@example.com
      send_resolved: true

And one day it send me with following email:

Capture.PNG


How can I put firing events and resolved events in different email? I have checked there are alertstate label in ALERTS metrics, wondering if I can use something like group_by: [alertname, alertstate] in config?

Christian Hoffmann

unread,
Jun 15, 2019, 2:45:48 AM6/15/19
to xud...@gmail.com, Prometheus Users
On 2019-05-16 08:04, xud...@gmail.com wrote:
> Hi, I configured alert manager as follow:
>
> route:
>     receiver: alert-receiver
>     group_wait: 30s
>     group_interval: 5m
>     repeat_interval: 24h
>     group_by: [alertname]
> receivers:
> - name: "alert-receiver"
>   email_configs:
>     - to: x...@example.com
>       send_resolved: true
>
> And one day it send me with following email:
>
> Capture.PNG
>
>
> How can I put firing events and resolved events in different email? I
> have checked there are alertstate label in ALERTS metrics, wondering if
> I can use something like group_by: [alertname, alertstate] in config?

I would also have suggested grouping by alertstate. Did you try it? Does
it work?

Kind regards,
Christian

kalai ganeshan

unread,
Jan 19, 2021, 1:25:15 AM1/19/21
to Prometheus Users
Anyone has idea on this ? I am in same scenario. I am getting FIRING , RESOLVED in same mail. Is there a way to split them in separate mails ? 

kalai ganeshan

unread,
Feb 22, 2021, 9:31:12 AM2/22/21
to Prometheus Users
Hi team, 

     I am still looking for this info. Is there a way to separate FIRING , RESOLVED into different mails completely ? 

Vũ Đạt

unread,
Dec 7, 2022, 4:32:15 AM12/7/22
to Prometheus Users
same: i want sent Resolved to channel Resolved telegram and sent Firing to channel Firing telegram, how can i do it, ,2022 year?
routes:
    - receiver: "telegram-critical"
      match_re:
        severity: "critical"
        alertstate: "firing"
      group_wait: 10s
      continue: true

    - receiver: "telegram-warning"
      match_re:
        severity: "warning"
        alertstate: "firing"
      group_wait: 10s
      continue: true

    - match_re:
        severity: "warning"
        alertstate: "resloved"
      receiver: "telegram-resolved"
      continue: false
Vào lúc 21:31:12 UTC+7 ngày Thứ Hai, 22 tháng 2, 2021, kalaiga...@gmail.com đã viết:

Bryan Chen

unread,
Apr 8, 2025, 8:20:14 AMApr 8
to Prometheus Users
Any solution?
Reply all
Reply to author
Forward
0 new messages