Issue with service notification and multiple contact groups

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
ghuey
Posts: 13
Joined: Mon Jan 24, 2011 9:25 am

Issue with service notification and multiple contact groups

Post by ghuey »

First I assume that it is even possible to use multiple contact groups since I would not really know why the would exist otherwise? However, if I am wrong please correct me.

My current default "admin" contactgroup works exactly as expected. I can have one or more individual contacts assigned to that default group and they all receive emails without issue.

I am not using the default notification, but instead using the following from Frank4dd:

/usr/local/nagios/libexec/nagios_send_service_mail.pl \ -H 172.30.1.12 -r $CONTACTEMAIL$ -f html -u

Again this script works fantastic with default admin ContactGroup, however when I add a second group it seems to be totally ignored by some process in the chain. I can see the second group is definitely added to the service.cfg definition according to the objects.cache file:

Code: Select all

define service {
        host_name       TestHost
        service_description     check_ping
        check_period    24x7
        check_command   check_ping!20,80%!30,90%
        contact_groups  TestGroup,admins
        notification_period     24x7
        initial_state   o
        check_interval  5.000000
        retry_interval  1.000000
        max_check_attempts      3
        is_volatile     0
        parallelize_check       1
        active_checks_enabled   1
        passive_checks_enabled  0
        obsess_over_service     1
        event_handler_enabled   0
        low_flap_threshold      0.000000
        high_flap_threshold     0.000000
        flap_detection_enabled  1
        flap_detection_options  o,w,u,c
        freshness_threshold     86400
        check_freshness 0
        notification_options    u,w,c,r
        notifications_enabled   1
        notification_interval   15.000000
        first_notification_delay        0.000000
        stalking_options        n
        process_perf_data       1
        failure_prediction_enabled      1
        retain_status_information       1
        retain_nonstatus_information    1
        }
So once again, every contact in the admin contactgroup works fine, it is only the SECOND (TestGroup) contactgroup that does not work. Any advice on how to troubleshoot this would be very appreciated.

Thanks,
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Issue with service notification and multiple contact gro

Post by Box293 »

ghuey wrote:First I assume that it is even possible to use multiple contact groups since I would not really know why the would exist otherwise? However, if I am wrong please correct me.
Yes it should work fine.

Can you post the definitions for both contact groups and at least two contacts from each group please. Also the command definition for host and service notifications that these contacts use.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Locked