Issues with setting up alerting

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
dbsaust
Posts: 76
Joined: Mon Dec 06, 2010 12:41 am

Issues with setting up alerting

Post by dbsaust »

Hi.

I have been struggling with this for a few days now, but despite trying every variable possible I can not get email alerts to be sent to contacts/groups, the only alerts are going out to the email address attached to the user nagios admin.

Things I have done
Made sure notifications are enabled
Generated test mails successfully
Generated mails to any email address associated with USER nagios admin.
Set-up several contacts, making sure time periods are 24x7 and host/service options are set to d u r f s and assigned the contacts to the host for alerts
added host/service command = Notify-host-by-Email or XI_host_event_handler or XI_host_notification_handeler
Set-up contact groups and added contacts into group, then assigned the group to the host
made sure the contacts are assigned to the group and then adding the group to the contact etc

I thought i was already pretty familiar with the Nagios tool from previous job's. But I can't help think either I'm not, the installation is faulty, or I am missing something obvious. Any support would be welcomed, please advise if you need any log/config files to assist troubleshooting.
rdedon
Posts: 578
Joined: Sat Nov 20, 2010 4:51 pm

Re: Issues with setting up alerting

Post by rdedon »

Hello,
some additional information would be great. Config/logs and screenshots from CCM/contacts/modify may be helpful. Also, was this off of a generic template? Are there any possible firewall issues that may prevent users from receiving?

I am trying to duplicate the issue here on a test machine.

Thanks!
Rene deDon
Technical Team
___
Nagios Enterprises, LLC
Web: http://www.nagios.com
dbsaust
Posts: 76
Joined: Mon Dec 06, 2010 12:41 am

Re: Issues with setting up alerting

Post by dbsaust »

I have attached all config files, I am only testing on the host AAAATEST once this is working i will roll out to all other hosts.
Also screen shot of the contact Manager and the Contact group that manger belongs too.

Re: Firewall issues, there seems no problem with this side as when i select alerting to go to myself (nagiosadmin) any email entered against nagios admin is successfully receiving test alerts.
1294899481.tar.gz
Groupt_Manager.JPG
Contact_Manager.JPG
You do not have the required permissions to view the files attached to this post.
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Issues with setting up alerting

Post by mguthrie »

The configurations looks like they should work ok, so I'm sure we're just missing something small somewhere. Are these contacts also "users" for the XI interface? If they are you may want to check the following page to make sure the notifications are turned on for the user settings.

Login or Masquerade as the user(s) who isn't receiving notifications.
Configuration->My Account Settings->Notification Preferences - make sure your preferred checkboxes are selected.
->Notification Methods - make sure the email checkbox is selected.

If those additional contacts are not XI users, and are only contacts, try matching the settings for the nagiosadmin exactly. Particularly, set your template to generic-contact, xi_generic_contact.
dbsaust
Posts: 76
Joined: Mon Dec 06, 2010 12:41 am

Re: Issues with setting up alerting

Post by dbsaust »

They are only Contacts, so I can confirm alerts go to user details with no issue. But do not go to contacts.


Also Does the user email address override anything in the contacts email address?
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Issues with setting up alerting

Post by mguthrie »

We'll have to see if we can recreate your issue.
Also Does the user email address override anything in the contacts email address?
The XI user management panel will create contacts if that option is selected, so if the name is the same I'm guessing it would override the CCM settings.
dbsaust
Posts: 76
Joined: Mon Dec 06, 2010 12:41 am

Re: Issues with setting up alerting

Post by dbsaust »

Ok thanks, my site is currently in development, so If functionality is available I would be happy to provide remote access to my setup.
I refreshed all the contact settings and escalation groups yesterday and started again, with the same results.
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Issues with setting up alerting

Post by mguthrie »

I discussed this with our lead developer today, and it sounds like XI is designed to have it's contact's set up through the Admin->Manage Users page, more than the Core Config Manager. Here's a document that explains the details of this, and how XI differs from Core.

http://assets.nagios.com/downloads/nagi ... ndcontacts
dbsaust
Posts: 76
Joined: Mon Dec 06, 2010 12:41 am

Re: Issues with setting up alerting

Post by dbsaust »

Ok, i have set all contacts up as users now, but still can not seem to get any of the additional address' configured to work.
Summary
Email address for notification coming from User email address only
so $CONTACTEMAIL$ within xi_host_notification_handler is not reading from contact details
Also i cannot get $CONTACTPAGER$ or $CONTACTADDRESSn$ (where n = 1-6 etc) to be picked up. Should adding the parameters to xi_host_notification_handler be sufficient?

i.e for Pager in xi_host_notification_handler
/usr/bin/php /usr/local/nagiosxi/scripts/handle_nagioscore_notification.php --notification-type=host --contact="$CONTACTNAME$" --contactemail="$CONTACTEMAIL$" --contactpager="$CONTACTPAGER$" --type=$NOTIFICATIONTYPE$ --escalated="$NOTIFICATIONISESCALATED$" --author="$NOTIFICATIONAUTHOR$" --comments="$NOTIFICATIONCOMMENT$" --host="$HOSTNAME$" --hostaddress="$HOSTADDRESS$" --hostalias="$HOSTALIAS$" --hoststate=$HOSTSTATE$ --hoststateid=$HOSTSTATEID$ --lasthoststate=$LASTHOSTSTATE$ --lasthoststateid=$LASTHOSTSTATEID$ --hoststatetype=$HOSTSTATETYPE$ --currentattempt=$HOSTATTEMPT$ --maxattempts=$MAXHOSTATTEMPTS$ --hosteventid=$HOSTEVENTID$ --hostproblemid=$HOSTPROBLEMID$ --hostoutput="$HOSTOUTPUT$" --longhostoutput="$LONGHOSTOUTPUT$" --datetime="$LONGDATETIME$"
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: Issues with setting up alerting

Post by mguthrie »

Are you using the Core Config Manager to handle contact settings, or the XI user account settings? I don't know all of the ins and outs of how XI controls the contact settings, but I recommend managing all of your user's settings for email, notifications, timeperiods, etc from the Configure->My Account Settings, and then the multiple Notification settings pages. Email notifications are disabled by default for a new user in XI.
Locked