Issue sending alerts to All contacts within a Contact Groups

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
heritages
Posts: 58
Joined: Thu Jan 16, 2014 11:55 am

Issue sending alerts to All contacts within a Contact Groups

Post by heritages »

I have created 4 users
User 1 - Email Address 1
User 1 - Email Address 2 (sends SMS Alert)
User 2 - Email Address 1
User 2 - Email Address 2 (sends SMS Alert)

Created 3 contact groups
Contact Group - IT Infrastructure 24-7 Email
User 1 - Email Address 1
User 2 - Email Address 1
Contact Group - IT Infrastructure 24-7 SMS
User 1 - Email Address 2 (sends SMS Alert)
User 2 - Email Address 2 (sends SMS Alert)
Contact Group - IT Infrastructure 24-7 Email SMS
Contact Group - IT Infrastructure 24-7 SMS
Contact Group - IT Infrastructure 24-7 Email

When I assign Contact Group - IT Infrastructure 24-7 Email SMS that has nested contact groups I'm finding that I only receive the alerts for the users in Contact Group - IT Infrastructure 24-7 SMS and not Contact Group - IT Infrastructure 24-7 Email.

The same applies when I add both contact groups Contact Group - IT Infrastructure 24-7 Email and Contact Group - IT Infrastructure 24-7 SMS directly to the Alerts tab on the Host, I only receive the SMS alerts and not the Email alerts.

I've verified in the Notifications screen that only the SMS alerts are being sent.

Note, if I only add the group Contact Group - IT Infrastructure 24-7 Email then we are receiving the email alerts with out any issue.

Any ideas why this is happening and a suggested solution
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Issue sending alerts to All contacts within a Contact Gr

Post by sreinhardt »

I just want to verify, these are 4 separate users and contacts, and not just 2 users with both sms and email settings set? What notification commands are you using for them?
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
heritages
Posts: 58
Joined: Thu Jan 16, 2014 11:55 am

Re: Issue sending alerts to All contacts within a Contact Gr

Post by heritages »

Yes I created 4 separate users because I wanted to use an email address to send an SMS as well I wanted to separate when to send an email and when to send an SMS.

Where can I find the notification command?
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Issue sending alerts to All contacts within a Contact Gr

Post by sreinhardt »

The notification commands would be in the contact configuration options within CCM.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
heritages
Posts: 58
Joined: Thu Jan 16, 2014 11:55 am

Re: Issue sending alerts to All contacts within a Contact Gr

Post by heritages »

I'm going to guess that you're asking about
CCM > Alerting > Contacts > <user> > Alert Settings > Manage Host Notifications Commands
if so then that is not set. But then non of my users were set yet the SMS alerts are going out.

Let me know if this is what you were looking for.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Issue sending alerts to All contacts within a Contact Gr

Post by lmiltchev »

Yes I created 4 separate users because I wanted to use an email address to send an SMS as well I wanted to separate when to send an email and when to send an SMS.
Log in as each user, and try to send a test email/sms. Check to see if you can receive it.
Note: If you created users, which are also monitoring contacts, they should be using the "xi_host_notification_handler" and "xi_service_notification_handler" commands.
Be sure to check out our Knowledgebase for helpful articles and solutions!
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Issue sending alerts to All contacts within a Contact Gr

Post by slansing »

SMS will go out to your users regardless of the contact commands I believe, as they are handled differently. You should have the xi_host and xi_service notification commands in those fields in the CCM, if you are not linking users to these contacts then you can just use the notify_host and notify_service commands:

http://assets.nagios.com/downloads/nagi ... ations.pdf
heritages
Posts: 58
Joined: Thu Jan 16, 2014 11:55 am

Re: Issue sending alerts to All contacts within a Contact Gr

Post by heritages »

I went into each contact under CCM > (Contact Name) > Alert Settings > Manage Host Notifications Commands and added xi_host_notification_handler and xi_service_notification_handler to the service command.

Still only the alert to the users heritagesms and cadranelsms were sent.
technick
Posts: 49
Joined: Tue Feb 04, 2014 10:30 am
Location: Denver, CO

Re: Issue sending alerts to All contacts within a Contact Gr

Post by technick »

I know this doesn't directly answer your issue but this could help you find the answer.

When Nagios reads in its configuration files, it creates a cache files with every object defined and the properties they inherit.

Check out /usr/local/nagios/var/objects.cache
----------------------
Nagios Jedi in training.
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Issue sending alerts to All contacts within a Contact Gr

Post by sreinhardt »

This is a pretty good idea, it never hurts to check how nagios actually "compiled" the configs into the objects.cache file. Specifically I would look for the contact group object within it.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
Locked