Configure Email Alerts using an internal Nagios Xi

This board serves as an open discussion and support collaboration point for Nagios XI. NOTE: Nagios XI customers should use the Customer Support forum to obtain expedited support.

Configure Email Alerts using an internal Nagios Xi

Postby mamir » Tue Oct 22, 2019 9:58 am

Hello Support,

I would need to use something within Nagios Xi such as internal SMTP or setup something like POSTFix in order to send out alerts to our company emails, can't use any third party SMTP or our company SMTP, so only option is to use something internally in Nagios Xi to send out all the alerts to our company email addresses. Please, help.
mamir
 
Posts: 57
Joined: Tue Mar 12, 2019 9:50 am

Re: Configure Email Alerts using an internal Nagios Xi

Postby mamir » Tue Oct 22, 2019 10:14 am

Ok. instead of SMTP option, I have used sendfrom Outbound Mail Settings Option & using one of our internal email address.

Please, confirm if that will work well to send out the email alerts as well? instead of using any SMTP server. What type of email system does Send from uses by the way, just curious to know.
Attachments
Capture.JPG
mamir
 
Posts: 57
Joined: Tue Mar 12, 2019 9:50 am

Re: Configure Email Alerts using an internal Nagios Xi

Postby benjaminsmith » Tue Oct 22, 2019 11:38 am

Hello @mamir,
What type of email system does Send from uses by the way, just curious to know.

It will use the default MTA (Mail Transfer Agent) provided by the Linux distribution. This is typically sendmail or postfix.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
benjaminsmith
 
Posts: 2000
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Configure Email Alerts using an internal Nagios Xi

Postby mamir » Tue Oct 22, 2019 11:42 am

Ok. Is this postfix feature built in Nagios Xi already when I use Send From Email to send out the alerts?
mamir
 
Posts: 57
Joined: Tue Mar 12, 2019 9:50 am

Re: Configure Email Alerts using an internal Nagios Xi

Postby benjaminsmith » Tue Oct 22, 2019 11:46 am

Hello,

Yes, it installed by CentOS. Send a test mail and check the mail logs if you don't receive the message.

Code: Select all
/var/log/maillog
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
benjaminsmith
 
Posts: 2000
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Configure Email Alerts using an internal Nagios Xi

Postby mamir » Tue Oct 22, 2019 1:45 pm

Ok understood. Ok a different note: I need to limit the notification alerts. I want to check a service or a host every minute. If either a host or a service is down, like to be notified immediately, but only one notification alert come in for the next 600 minutes & if it is recovered before 600 minutes, i should just get one recovery email notification. Please, assist, where exactly for a host or services, i can set it up. I'm getting multiple notifications for the same host or services in one minute. Therefore, i just want to limit & get only one right away & then 600 minutes should be the wait time for the second notification if its still down. Please, help me.
mamir
 
Posts: 57
Joined: Tue Mar 12, 2019 9:50 am

Re: Configure Email Alerts using an internal Nagios Xi

Postby benjaminsmith » Tue Oct 22, 2019 2:02 pm

Hello @mamir,

You can accomplish this by setting the notification interval to 600.
notification_interval: This directive is used to define the number of "time units" to wait before re-notifying a contact that this host is still down or unreachable. Unless you've changed the interval_length directive from the default value of 60, this number will mean minutes. If you set this value to 0, Nagios will not re-notify contacts about problems for this host - only one problem notification will be sent out.


To set this in Nagios XI, go to Configure >Monitoring > Hosts or Services > Alert Settings.

notification-interval.png
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
benjaminsmith
 
Posts: 2000
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Configure Email Alerts using an internal Nagios Xi

Postby mamir » Tue Oct 22, 2019 2:46 pm

Capture1.JPG
Cap1
Capture1.JPG
Capture1.JPG


I have setup these settings, I stopped one service just for testing & host was still up. But I recieved 2 service down alerts & 2 host UP alerts.

Please, check my settings, what I'm missing here. Because I should have only recieved one service down alert, the second should only be recieved after every 600 minutes. Also why a HOST alert, is that expected, because for HOST if should only send it when a HOST is down or recovered correct?

This seems to be duplicate alerts one HOST UP & other email recieve at same time which is expected 1 service down alert.
Attachments
Capture3.JPG
Capture2.JPG
mamir
 
Posts: 57
Joined: Tue Mar 12, 2019 9:50 am

Re: Configure Email Alerts using an internal Nagios Xi

Postby benjaminsmith » Tue Oct 22, 2019 3:19 pm

Hello @mamir,
Also why a HOST alert, is that expected, because for HOST if should only send it when a HOST is down or recovered correct?

Are you certain the host was never down? Can you verify this in the state history or nagios logs.

If you're receiving duplicate notifications, check the contacts associated with the servers to make sure you do not have multiple contacts with the same email. Otherwise, it's possible that you have multiple nagios process running, run the following commands.

Code: Select all
systemctl stop nagios
pkill -9 -u nagios
systemctl start nagios
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.

Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
benjaminsmith
 
Posts: 2000
Joined: Wed Aug 22, 2018 4:39 pm
Location: saint paul

Re: Configure Email Alerts using an internal Nagios Xi

Postby mamir » Wed Oct 23, 2019 1:03 pm

Ok. There might be something off, so i reinstall Nagios Xi from scratch & now able to recieve just one alert. Thanks for your help.

so basically, when I add a new host, there is no modification needed correct, just notification interval, i can change to 600 minutes which will mean after my first down alert, it will not send another notification only after each 600 pass by correct.

We can close this loop. Thanks for your support again.
mamir
 
Posts: 57
Joined: Tue Mar 12, 2019 9:50 am

Next

Return to Nagios XI

Who is online

Users browsing this forum: No registered users and 4 guests