Message: A database connection error has been detected

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
daniel.c.marcos.jr
Posts: 4
Joined: Thu Aug 20, 2015 10:13 am

Message: A database connection error has been detected

Post by daniel.c.marcos.jr »

Hi,

I am encountering an error in nagiosxi gui after I updated our php from 5.3 to 5.4. Can you help us?

Message: A database connection error has been detected, we are attempting to repair the server, if the repair does not resolve the issue, please contact Nagios support.

Run the following from the CLI as root to attempt to repair the DB

/usr/local/nagiosxi/scripts/repair_databases.sh
Last edited by daniel.c.marcos.jr on Thu Aug 20, 2015 11:58 am, edited 1 time in total.
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Message: A database connection error has been detected,

Post by hsmith »

/usr/local/nagiosxi/scripts/repair_databases.sh
Did you try doing this?
Former Nagios Employee.
me.
daniel.c.marcos.jr
Posts: 4
Joined: Thu Aug 20, 2015 10:13 am

Re: Message: A database connection error has been detected,

Post by daniel.c.marcos.jr »

Thank you for your reply :D

yes. kindly see below for the screenshot. however the error still appears


===============
REPAIR COMPLETE
===============
+ /usr/local/nagiosxi/scripts/manage_services.sh restart ndo2db
Stopping ndo2db: done.
Starting ndo2db: done.
+ /usr/local/nagiosxi/scripts/manage_services.sh restart nagios
Running configuration check...
Stopping nagios:. done.
Starting nagios: done.
+ rm -f /usr/local/nagiosxi/scripts/repair_databases.lock
[root@HOFVA1226 nagiosxi]#
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Message: A database connection error has been detected,

Post by hsmith »

daniel.c.marcos.jr wrote:Thank you for your reply :D

yes. kindly see below for the screenshot. however the error still appears


===============
REPAIR COMPLETE
===============
+ /usr/local/nagiosxi/scripts/manage_services.sh restart ndo2db
Stopping ndo2db: done.
Starting ndo2db: done.
+ /usr/local/nagiosxi/scripts/manage_services.sh restart nagios
Running configuration check...
Stopping nagios:. done.
Starting nagios: done.
+ rm -f /usr/local/nagiosxi/scripts/repair_databases.lock
[root@HOFVA1226 nagiosxi]#
Can you post a screenshot of the GUI, and describe what you are doing at the time that you encounter this error please?
Former Nagios Employee.
me.
daniel.c.marcos.jr
Posts: 4
Joined: Thu Aug 20, 2015 10:13 am

Re: Message: A database connection error has been detected

Post by daniel.c.marcos.jr »

I attached the screenshot of my nagiosxi gui.


Below are the steps run by my colleague.

yum remove php-cli.x86_64 php-common.x86_64 php-mysql.x86_64 php-pdo.x86_64 php-xml.x86_64
yum install scl-utils
yum install rhscl-php54-*.noarch.rpm
yum install php54
You do not have the required permissions to view the files attached to this post.
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Message: A database connection error has been detected

Post by hsmith »

daniel.c.marcos.jr wrote:I attached the screenshot of my nagiosxi gui.


Below are the steps run by my colleague.

yum remove php-cli.x86_64 php-common.x86_64 php-mysql.x86_64 php-pdo.x86_64 php-xml.x86_64
yum install scl-utils
yum install rhscl-php54-*.noarch.rpm
yum install php54
How was XI installed? Did you use the fullinstall script, or download one of the prebuilt VMs? What are you running this on? (CentOS6/7/RHEL...)

Was there a particular reason for removing all of the php components that way vs yum update -y?
Former Nagios Employee.
me.
Locked