Hi Nagios Team,
Until last week, Nagios XI which I am running using the VMware was working well, but today when i tried to login, I got the following error:
DB Connect Error [nagiosxi]: Database connection failed DB Connect Error [nagiosxi]: Database connection failed DB Connect Error [nagiosxi]: Database connection failed
Then, I tried searching for solution in this forum, but suggestions were asked to check if mysql and postgresql was running.
After checking these in my case, mysql seems to be running by postgresql failed to start. It stopped, but failed to start the service.
And I tried running the suggested command: df -h
I have attached the output here, but it doesn't seem to be hard disk issue.
Please help! Thanks in advance!
DB Connect Error [nagiosxi]: Database connection failed DB C
DB Connect Error [nagiosxi]: Database connection failed DB C
You do not have the required permissions to view the files attached to this post.
Re: DB Connect Error [nagiosxi]: Database connection failed
Try to start the postgresql service, post the output here (looking for more information):
Code: Select all
service postgresql start
tail /var/lib/pgsql/pgstartup.logFormer 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.
"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.
Re: DB Connect Error [nagiosxi]: Database connection failed
Okay, I have tried the command given and attached here is the output.
You do not have the required permissions to view the files attached to this post.
-
slansing
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: DB Connect Error [nagiosxi]: Database connection failed
Have you tried starting Postgres with either of the commands shown in your picture? Can you also try the following "slight change":
Code: Select all
service postgresql start
tail -50 /var/lib/pgsql/pgstartup.logRe: DB Connect Error [nagiosxi]: Database connection failed
The following shows the output of the tail -50 /var/lib/pgsql/pgstartup.log
And I tried one of the command shown on the picture but it shoots me error as in the figure attached here.
When i tried to connecting it using psql command line tool, it threw me the following error.
You do not have the required permissions to view the files attached to this post.
-
sreinhardt
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: DB Connect Error [nagiosxi]: Database connection failed
Let's also do a "df -i" to check inodes since this has been a little bit. Additionally, did anything aside from this happen to your server? Such as power failures or disk issues? It seems that each time you start postgres it is starting for the very first time, initializing everything as though it was new.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
Re: DB Connect Error [nagiosxi]: Database connection failed
There was no issue on the server, we just had to restart the server last week.
And I tried 'df -i' command, following shows the output.
And I tried 'df -i' command, following shows the output.
You do not have the required permissions to view the files attached to this post.
-
sreinhardt
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: DB Connect Error [nagiosxi]: Database connection failed
When you restarted the server, was this done via power button or vmware restart action, or the actual shutdown -r\restart command in linux?
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
Re: DB Connect Error [nagiosxi]: Database connection failed
Run the following commands, and show the output:
Can you log in postgres by running the following command?
Code: Select all
echo "vacuum;vacuum analyse;vacuum full;"|psql nagiosxi postgres
service postgresql statusCode: Select all
psql nagiosxi nagiosxiBe sure to check out our Knowledgebase for helpful articles and solutions!