CCM issues after 1.7 upgrade

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
jsmurphy
Posts: 989
Joined: Wed Aug 18, 2010 9:46 pm

CCM issues after 1.7 upgrade

Post by jsmurphy »

After upgrading from 1.6 to 1.7 I started getting the following error when opening CCM: "Error connecting to database.", NagiosQL thankfully still works fine.

I noticed that nagiosxi/html/includes/components/ccm/config.inc.php had the default server and credentials in it (I don't know if this is supposed to have the default creds or not), I updated it to the correct details and restarted apache, but this doesn't seem to have resolved the issue.

nagiosxi/html/config.inc.php also has the correct server and credentials in it for nagiosql.

It appears to be attempting to connect to the localhost still but I can't find anywhere else that these settings might live, to point it at the right server:
[Thu Apr 11 10:52:41 2013] [error] [client 172.31.121.248] PHP Warning: mysql_real_escape_string(): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) in /usr/local/nagiosxi/html/includes/components/ccm/includes/common_functions.inc.php on line 378, referer: http://nagioshost/nagiosxi/includes/com ... -index.php
User avatar
BanditBBS
Posts: 2474
Joined: Tue May 31, 2011 12:57 pm
Location: Scio, OH
Contact:

Re: CCM issues after 1.7 upgrade

Post by BanditBBS »

jsmurphy wrote:nagiosxi/html/includes/components/ccm/config.inc.php
nagiosxi/html/config.inc.php
I can tell you that I am running 1.7 as well. My nagiosxi/html/includes/components/ccm/config.inc.php still has localhost connection information in it. The nagiosxi/html/config.inc.php does have the offloaded mysql information in it. Mine is working fine.

Check this post and my reply - http://support.nagios.com/forum/viewtop ... 875#p36387
2 of XI5.6.14 Prod/DR/DEV - Nagios LogServer 2 Nodes
See my projects on the Exchange at BanditBBS - Also check out my Nagios stuff on my personal page at Bandit's Home and at github
mguthrie
Posts: 4380
Joined: Mon Jun 14, 2010 10:21 am

Re: CCM issues after 1.7 upgrade

Post by mguthrie »

Try running:

Code: Select all

touch /usr/local/nagiosxi/html/config.inc.php
This should force the CCM to update the credentials.
User avatar
jsmurphy
Posts: 989
Joined: Wed Aug 18, 2010 9:46 pm

Re: CCM issues after 1.7 upgrade

Post by jsmurphy »

That killed the problem dead, thanks mike :)
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: CCM issues after 1.7 upgrade

Post by lmiltchev »

Marking this issue as resolved.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked