No alerts going out from Nagios

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: No alerts going out from Nagios

Post by rkennedy »

rkennedy wrote: Sometimes notifications stop working because SQL crashes, try running /usr/local/nagiosxi/scripts/repair_databases.sh to see if that clears it up.
Did rrunning this output anything?

Looking at your profile, I am seeing this in your apache logs -

Code: Select all

[Tue May 24 16:53:42.206072 2016] [:error] [pid 16390] [client ::1:59553] PHP Warning:  mysql_pconnect(): Link to server lost, unable to reconnect in /usr/local/nagiosxi/html/db/adodb/drivers/adodb-mysql.inc.php on line 383
[Tue May 24 16:53:42.206323 2016] [:error] [pid 16390] [client ::1:59553] PHP Notice:  Undefined variable: result in /usr/local/nagiosxi/html/includes/db.inc.php on line 249
[Tue May 24 16:53:42.246134 2016] [:error] [pid 16390] [client ::1:59553] PHP Warning:  mysql_pconnect(): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /usr/local/nagiosxi/html/db/adodb/drivers/adodb-mysql.inc.php on line 383
[Tue May 24 16:53:42.246243 2016] [:error] [pid 16390] [client ::1:59553] PHP Notice:  Undefined variable: result in /usr/local/nagiosxi/html/includes/db.inc.php on line 249
[Tue May 24 16:53:42.295400 2016] [:error] [pid 16390] [client ::1:59553] PHP Warning:  mysql_pconnect(): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /usr/local/nagiosxi/html/db/adodb/drivers/adodb-mysql.inc.php on line 383
[Tue May 24 16:53:42.295449 2016] [:error] [pid 16390] [client ::1:59553] PHP Notice:  Undefined variable: result in /usr/local/nagiosxi/html/includes/db.inc.php on line 249
I suspect this has to do with it not working since SQL is unable to connect at times.
Former Nagios Employee
dfmco
Posts: 257
Joined: Wed Dec 04, 2013 11:05 am

Re: No alerts going out from Nagios

Post by dfmco »

There are a lot of entries like this one:
- recovering (with sort) MyISAM-table 'nagios_commands.MYI'
Data records: 124
- Fixing index 1
- Fixing index 2

So does that mean it is fixing things or is there some other bit of info I should be looking for?
dfmco
Posts: 257
Joined: Wed Dec 04, 2013 11:05 am

Re: No alerts going out from Nagios

Post by dfmco »

So at some point the nagiosadmin started getting alerts but my ID ([email protected]) is still not getting the alerts. I tried forcing the custom notification in case it was an issue with my ID but that did not work either.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: No alerts going out from Nagios

Post by Box293 »

dfmco wrote:There are a lot of entries like this one:
- recovering (with sort) MyISAM-table 'nagios_commands.MYI'
Data records: 124
- Fixing index 1
- Fixing index 2

So does that mean it is fixing things or is there some other bit of info I should be looking for?
This is OK. What you are looking for is errors like "Cannot repair xxx due to yyy".
dfmco wrote:So at some point the nagiosadmin started getting alerts but my ID ([email protected]) is still not getting the alerts. I tried forcing the custom notification in case it was an issue with my ID but that did not work either.
Is [email protected] a user in XI, or just a contact?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
dfmco
Posts: 257
Joined: Wed Dec 04, 2013 11:05 am

Re: No alerts going out from Nagios

Post by dfmco »

There were no repair errors and dflick is a user and a contact (I selected the contact when setting up)
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: No alerts going out from Nagios

Post by Box293 »

Can you go to:

Admin > Users > Manage Users
Edit the user dflick
Send us a screenshot of this page
Click Cancel

Click the Masquerade As icon (eyeball) for dflick
Click Continue
Now you are logged in as dflick
Click the username in the top right corner
Under Notification Options click Notification Methods
Are notifications enabled?

Go into CCM
Alerting > Contacts
Click the Disk icon in the actions pane for dflick
Paste the text config here
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
dfmco
Posts: 257
Joined: Wed Dec 04, 2013 11:05 am

Re: No alerts going out from Nagios

Post by dfmco »

receive alerts via email is checked.
You do not have the required permissions to view the files attached to this post.
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: No alerts going out from Nagios

Post by Box293 »

Go into CCM
Alerting > Contacts
Click the Disk icon in the actions pane for dflick
Paste the text config here for the contact dflick
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
dfmco
Posts: 257
Joined: Wed Dec 04, 2013 11:05 am

Re: No alerts going out from Nagios

Post by dfmco »

###############################################################################
#
# Contact configuration file
#
# Created by: Nagios Core Config Manager 2.5.2
# Date: 2016-05-24 23:10:28
# Version: Nagios 3.x config file
#
# --- DO NOT EDIT THIS FILE BY HAND ---
# Nagios CCM will overwrite all manual settings during the next update if you
# would like to edit files manually, place them in the 'static' directory or
# import your configs into the CCM by placing them in the 'import' directory.
#
###############################################################################

define contact {
contact_name dflick
alias Daniel Flick
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 c,r,s
email [email protected]
use xi_contact_generic
}

define contact {
contact_name nagiosadmin
alias Nagios Administrator
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 c,r,s,
host_notification_commands xi_host_notification_handler
service_notification_commands xi_service_notification_handler
email [email protected]
use xi_contact_generic
}

###############################################################################
#
# Contact configuration file
#
# END OF FILE
#
###############################################################################
dfmco
Posts: 257
Joined: Wed Dec 04, 2013 11:05 am

Re: No alerts going out from Nagios

Post by dfmco »

I am finding that this server is ABYSMALLY slow. I have an Identical server that I did a restore to and I will work on that one going forward and rebuild the one we have been working on. I think the server has some issues.
Locked