Heavy,
Thank you for your helpful response. Makes sense.
I have myself as a member of multiple contact groups. I set up a rule per contact group as you mentioned with the following filters:
- Notify all contacts of the notified host or service.
- Restrict by contact groups
I had hoped that the first filter would build up a list of contacts attached to the host or service, and the second would filter out only a singular contact group per rule to match.
However, I am notified for each contact group I’m listed in. It seems as if filter 2 populates contacts based on the contract group given in filter 2, even if filter 1 is empty.
For example, for contact groups A, B, C where USER1 is in A, B and USER2 is in B, and USER3 is in C. HOST is only attached to contact group B, C:
2023-10-21 11:38:01,310 [20] [cmk.base.notify] Analysing notification (HOST;Memory) context with 52 variables
2023-10-21 11:38:01,311 [20] [cmk.base.events] Previous service hard state not known. Allowing all states.
2023-10-21 11:38:01,312 [20] [cmk.base.notify] Global rule 'Notify all A contacts'...
2023-10-21 11:38:01,312 [20] [cmk.base.notify] -> matches!
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - skipping contact USER2: he/she is not member of the contact group A (his groups are B)
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - skipping contact USER3: he/she is not member of the contact group A (his groups are C)
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - adding notification of USER1 via mail
2023-10-21 11:38:01,312 [20] [cmk.base.notify] Global rule 'Notify all B contacts'...
2023-10-21 11:38:01,312 [20] [cmk.base.notify] -> matches!
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - skipping contact USER3: he/she is not member of the contact group B (his groups are C)
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - adding notification of USER1, USER2 via mail
2023-10-21 11:38:01,312 [20] [cmk.base.notify] Global rule 'Notify all C contacts on second alert'...
2023-10-21 11:38:01,312 [20] [cmk.base.notify] -> matches!
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - skipping contact USER1: he/she is not member of the contact group C (his groups are A, B)
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - skipping contact USER2: he/she is not member of the contact group C (his groups are B)
2023-10-21 11:38:01,312 [20] [cmk.base.notify] - adding notification of USER3 via asciimail
2023-10-21 11:38:01,313 [20] [cmk.base.notify] Executing 3 notifications:
2023-10-21 11:38:01,313 [20] [cmk.base.notify] * would notify USER1 via mail, parameters: from, bulk_sort_order, graphs_per_notification, notifications_with_graphs, bulk: no
2023-10-21 11:38:01,313 [20] [cmk.base.notify] * would notify USER1, USER2 via mail, parameters: from, bulk_sort_order, graphs_per_notification, notifications_with_graphs, bulk: no
2023-10-21 11:38:01,313 [20] [cmk.base.notify] * would notify USER3 via asciimail, parameters: from, host_subject, service_subject, common_body, host_body, service_body, bulk: no
Where USER1 is notified for contact group A even though HOST is not attached to contact group A.