Nagios throwing DB errors on apache

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Nagios throwing DB errors on apache

Post by slansing »

Are you noticing any hindered performance on the front end? Are certain pages/components/functions broken or not working properly? Nothing out of the ordinary compared to mine at the initial look... when this error is dumped to the error log, what page/function are you trying to view/use?
johndoe
Posts: 114
Joined: Fri Oct 28, 2011 10:14 am

Re: Nagios throwing DB errors on apache

Post by johndoe »

Sure, reports don-t work, page just hangs and i cant access any more pages... only by cleaning up my session
Nagios XI 2012R2.8c Running on Ubuntu 12.04 Using 99% passive checks for monitoring
Monitoring nearly 800 Passive services spread through roughly 40 machines
Running on an 8 core, KVM virtualized VM, with 15 GB of RAM and using RAMDisk
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Nagios throwing DB errors on apache

Post by lmiltchev »

Go to Admin->System Profile->Download Profile->save the "profile.zip" file and PM it to any of us on the Nagios Tech Support Team.
Be sure to check out our Knowledgebase for helpful articles and solutions!
johndoe
Posts: 114
Joined: Fri Oct 28, 2011 10:14 am

Re: Nagios throwing DB errors on apache

Post by johndoe »

sent as requested
Nagios XI 2012R2.8c Running on Ubuntu 12.04 Using 99% passive checks for monitoring
Monitoring nearly 800 Passive services spread through roughly 40 machines
Running on an 8 core, KVM virtualized VM, with 15 GB of RAM and using RAMDisk
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Nagios throwing DB errors on apache

Post by lmiltchev »

We got the profile.zip. Give us some time to review the configs and logs. Thanks!
Be sure to check out our Knowledgebase for helpful articles and solutions!
johndoe
Posts: 114
Joined: Fri Oct 28, 2011 10:14 am

Re: Nagios throwing DB errors on apache

Post by johndoe »

Guys, just a note here, yesterday when configuring something else i noticed the https certificate was expired! Could this be the case? We use self signed certificates and after i changed it to our new one i get this:

Code: Select all

WGET From URL: https://localhost/nagiosql/index.php 
Running:
/usr/bin/wget https://localhost/nagiosql/index.php 
--2014-03-14 13:06:09-- https://localhost/nagiosql/index.php
Resolving localhost... ::1, 127.0.0.1
Connecting to localhost|::1|:443... connected.
ERROR: cannot verify localhost's certificate, issued by "/C=XXXXXXXXXX":
Unable to locally verify the issuer's authority.
ERROR: certificate common name "monitoring" doesn't match requested host name "localhost".
To connect to localhost insecurely, use '--no-check-certificate'.
Sounds like a vague possibility but can it be related? If not, how do i get nagios to ignore this, a.k.a where do i add the '--no-check-certificate' part ?
Nagios XI 2012R2.8c Running on Ubuntu 12.04 Using 99% passive checks for monitoring
Monitoring nearly 800 Passive services spread through roughly 40 machines
Running on an 8 core, KVM virtualized VM, with 15 GB of RAM and using RAMDisk
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: Nagios throwing DB errors on apache

Post by abrist »

You most likely need to create an alias in /etc/hosts:

Code: Select all

127.0.0.1  localhost monitoring
What does yours look like?

Code: Select all

cat /etc/hosts
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
johndoe
Posts: 114
Joined: Fri Oct 28, 2011 10:14 am

Re: Nagios throwing DB errors on apache

Post by johndoe »

abrist wrote:You most likely need to create an alias in /etc/hosts:

Code: Select all

127.0.0.1  localhost monitoring
What does yours look like?

Code: Select all

cat /etc/hosts
Thanks but Unfortunately solving this will only complain about a self signed certificate (which is true since it is one).
I believe this doesn-t affect anything on nagios other than the lousy browser message we connect to it so will leave that one for now.

Let-s go back to the DB errors issue itself.
Nagios XI 2012R2.8c Running on Ubuntu 12.04 Using 99% passive checks for monitoring
Monitoring nearly 800 Passive services spread through roughly 40 machines
Running on an 8 core, KVM virtualized VM, with 15 GB of RAM and using RAMDisk
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: Nagios throwing DB errors on apache

Post by scottwilkerson »

Can you run the following

Code: Select all

cat /etc/php.ini|grep ixed
and make sure it reads

Code: Select all

extension=ixed.5.4.lin

Also, I believe the vew version of PHP you have has strict standards on by default, you may need to run the following

Code: Select all

sed -i 's/&NewADOConnection/NewADOConnection/g' /usr/local/nagiosxi/html/includes/db.inc.php
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
johndoe
Posts: 114
Joined: Fri Oct 28, 2011 10:14 am

Re: Nagios throwing DB errors on apache

Post by johndoe »

Thanks scott,

While that seems to clean up the initial error, a few more came up which seem to be related:
Note that i had the ixed.5.3.lin and not ixed.5.4.lin

Error 1:

Code: Select all

[Tue Mar 18 12:30:04 2014] [error] [client XXXXX] PHP Strict Standards:  Only variables should be assigned by reference in /usr/local/nagiosxi/html/includes/configwizards/ssh-expect/ssh-expect.inc.php on line 488, referer: https://XXXXX/nagiosxi/config/
Error 2: This one relates to a client that is only opened on a dashboard

Code: Select all

[Tue Mar 18 12:30:14 2014] [error] [client XXXXX] PHP Notice:  Undefined variable: dashletmode in /usr/local/nagiosxi/html/includes/components/xicore/dashlets-perfdata.inc.php on line 173
Error 3 : When going into Reports the session doesnt allow for any more pages to be opened until the nagios session is restarted.
Nagios XI 2012R2.8c Running on Ubuntu 12.04 Using 99% passive checks for monitoring
Monitoring nearly 800 Passive services spread through roughly 40 machines
Running on an 8 core, KVM virtualized VM, with 15 GB of RAM and using RAMDisk
Locked