Alerts not working

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
lance.peterson
Posts: 64
Joined: Wed Aug 05, 2015 11:10 am

Alerts not working

Post by lance.peterson »

I setup and SNMP alert on a UPS for when the voltage goes below a 110 Volts so I get the alert, but I do not get an alert. If I change it so I get an alert above that same voltage I get the alert right away. Why would I not get the alerts when going below but do above?
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Alerts not working

Post by lmiltchev »

You may see an alert in the nagios.log but you would receive an actual notification only if the services goes to HARD non-OK state or recovers from one. Was the service flapping when it went below the threshold? Was this a WARNING or a CRITICAL alert? It's possible that the xi user (contact) has configured his/her notification preferences in a way that notifications for some states are disabled.
Be sure to check out our Knowledgebase for helpful articles and solutions!
swolf

Re: Alerts not working

Post by swolf »

Hi @lance.peterson,

Would you mind showing us the exact check_command and arguments you used to configure this? There are a few different reasons this could happen and it'll be easier to determine if we can see your configs.

EDIT: It seems that @lmiltchev and I interpreted your issue differently. Are you having an issue where the alert shows in the log (and you don't get e-mailed), or an issue where you simply should get alerted and the alert never fires (i.e. the plugin does not go into a non-OK state).
lance.peterson
Posts: 64
Joined: Wed Aug 05, 2015 11:10 am

Re: Alerts not working

Post by lance.peterson »

I have the notification preferences selected for everything for test purposes and nothing is still coming through. I do see it in critical status on the Nagios console but I do not get alerted via email or text.

Attached is a screenshot of the config page with Arg1 copied below to show the whole thing.

-o .1.3.6.1.4.1.318.1.1.1.3.2.1.0 -C public -P 1 -l "V" -w 110: -c 110:

Do you need any other information beside this?
You do not have the required permissions to view the files attached to this post.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Alerts not working

Post by lmiltchev »

I do see it in critical status on the Nagios console but I do not get alerted via email or text.
Can you show us a screenshot of this page?

Also, go to Reports > State History > <your service> > State Type = Both > Run, and show a screenshot of that page too.

What is the output of the following command?

Code: Select all

/usr/local/nagios/libexec/check_snmp -H <ip address> -o .1.3.6.1.4.1.318.1.1.1.3.2.1.0 -C public -P 1 -l "V" -w 110: -c 110:
Be sure to check out our Knowledgebase for helpful articles and solutions!
lance.peterson
Posts: 64
Joined: Wed Aug 05, 2015 11:10 am

Re: Alerts not working

Post by lance.peterson »

See attached screenshot.

WHere do I run that command?
You do not have the required permissions to view the files attached to this post.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Alerts not working

Post by lmiltchev »

WHere do I run that command?
Normally, you would have to open a SSH (putty) session to the Nagios XI server, logged in as root, and run the command from the command line. However, after seeing the screenshot from the State History report, I don't think I need to see the command and the output of it. The service was in a HARD CRITICAL and HARD OK state, so you should have received notifications.

In order to troubleshoot this further, let's check a few more things:

1. Show a screenshot of the Notifications report for the same time period (as in the State History report):
Reports > Notifications > Limit To = <your service> > Run

2. Show the service config.
CCM > Services > <your service> >View Config

3. Go to Admin > Email Settings, and show a screenshot of the page.
Be sure to check out our Knowledgebase for helpful articles and solutions!
lance.peterson
Posts: 64
Joined: Wed Aug 05, 2015 11:10 am

Re: Alerts not working

Post by lance.peterson »

Couple notes.

I do get emials from other things.

Secondly I'm out of the office next monday and Tuesday so I won't be responding back until then.

See 3 screenshots.
You do not have the required permissions to view the files attached to this post.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Alerts not working

Post by lmiltchev »

You can see from the Notifications report that nagios did send notifications for the CRITICAL and OK states of "Input Voltage" service, so it is not an issue with Nagios.

Most likely, notifications are not received because of your SMTP settings. Are you sure that you are using the correct username (lance.peterson)? Isn't that supposed to be an email? To be frank, I never used smtp-relay.gmail.com and I don't know if it is going to work without SSL/TLS.

Can you send a test email from the "Mail Settings" page? Do you receive the test? Do you see any errors in the /usr/local/nagiosxi/tmp/phpmailer.log?
Be sure to check out our Knowledgebase for helpful articles and solutions!
lance.peterson
Posts: 64
Joined: Wed Aug 05, 2015 11:10 am

Re: Alerts not working

Post by lance.peterson »

I see it says it went critical but as you can see before I changed it so it was when the voltage was high I got a notification that worked fine. When I switched it so when the voltage went to zero that is when I do not get a notification. So I know my SMTP setting are fine, not to mention they work with every other issue. Is seems it just doesn't send anything when I have it set to send the notification on low voltage.

Username doesn't matter as it is not authenticating. It's just auto-filled there not actually saved.

Test message worked just fine. What the easiest way to get you that file. I'm not sure how to get it.
You do not have the required permissions to view the files attached to this post.
Locked