nagios email notifications not being sent

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

nagios email notifications not being sent

Post by benhank »

2011 R3
I am having an issue in which my nagios server is configured properly to send mail via snmp.
when I click on the "send test email option, I get the email.

When I click on the "Send custom notification" option for an object there is no email.
i have verified that the contact has been set up properly, but this issue persists. what makes it worse is that my notifications were working fine, and then nagios started sending notifications to the wrong people. and then this issue began.
when we checked the mail log this baffling error cropped up:

nagiosserver postfix/snmp [10282] :host myironport firewall refused to talk to me.
My mail guy told me that nagios should not be touching the firewall as the firewall only checks external mail coming in from outside.


I forgot to mention that this is happening on all 4 or my nagios servers.
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: nagios email notifications not being sent

Post by slansing »

When your notifications were being sent to the wrong people, what happened to cause this do you think? What changes were being made to the system?
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

Re: nagios email notifications not being sent

Post by benhank »

no there weren't any changes made. that's what baffled us. I have even deleted contacts but nagios still tried to email them, failed.
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: nagios email notifications not being sent

Post by slansing »

Under CCM > Content Management > Choose one of your contacts which is not receiving notifications > Let me know what you have defined under Manage Host Notification Commands, and Manage Service Notification Commands.
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

Re: nagios email notifications not being sent

Post by benhank »

Code: Select all

define contact {
	contact_name                  		bhankers
	alias                         		Be
	contactgroups                 		Nagios Enterprise monitoring Team
	host_notifications_enabled    		1
	service_notifications_enabled 		1
	host_notification_period      		24x7
	service_notification_period   		24x7
	host_notification_options     		d,u,r,f,s,
	service_notification_options  		w,u,c,r,f,s,
	host_notification_commands    		notify-host-by-email
	service_notification_commands 		notify-service-by-email
	can_submit_commands           		1
	retain_status_information     		1
	retain_nonstatus_information  		1
	email                         		Benjankerson@Atrilth.org
	use                           		xi_contact_generic,generic-contact,Nagios Monitoring team
	}	
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: nagios email notifications not being sent

Post by slansing »

Your Service, and Host notification handlers need to be set to:

xi_host_notification_handler

xi_service_notification_handler
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

Re: nagios email notifications not being sent

Post by benhank »

Hey thanks! not only that but I had sendmail, and postfix set up wrong. I would have replied sooner but I had to exit stage right before i could. on a side note, whats the difference between the two settings?
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
User avatar
lmiltchev
Former Nagios Staff
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: nagios email notifications not being sent

Post by lmiltchev »

The "xi_host_notification_handler" and "xi_service_notification_handler" are the default notification handlers in Nagios XI. They should be used by all users, including nagiosadmin. The "notify-host-by-email" and "notify-service-by-email" are notification handlers for contacts only (mainly used in Nagios Core). Contacts and users and similar but not the same. Please, review our documentation on the topic:

http://assets.nagios.com/downloads/nagi ... ntacts.pdf

Hope this helps.
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
benhank
Posts: 1264
Joined: Tue Apr 12, 2011 12:29 pm

Re: nagios email notifications not being sent

Post by benhank »

Thanks! you have really helped me on this one, now I wont be posting that I can't get multi tenancy working. =D
. you can lock this I am all set!
Proudly running:
NagiosXI 5.4.12 2 node Prod Env 2500 hosts, 13,000 services
Nagiosxi 5.5.7(test env) 2500 hosts, 13,000 services
Nagios Logserver 2 node Prod Env 500 objects sending
Nagios Network Analyser
Nagios Fusion
User avatar
lmiltchev
Former Nagios Staff
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: nagios email notifications not being sent

Post by lmiltchev »

I am glad I could help! :D
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked