We are having database issues and tried to run the database repair script, but the script is failing to stop the mysqld service. We also cant stop it manually without the script. We are seeing the following errors in the syslog:
Error: Could not connect to MySQL database: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Sep 22 14:01:27 xxxxxxxx nagios: ndomod: Error writing to data sink! Some output may get lost. 4832 queued items to flush.
Sep 22 14:01:43 xxxxxxxx nagios: ndomod: Successfully reconnected to data sink! 935 items lost, 5000 queued items to flush.
Any idea on what caused this or how to fix it?
MySQL database error
Re: MySQL database error
What is the version of Nagios XI that you are currently using?
Can you run the following commands, and show the output in code wraps?
If using mysqld:
If using mariadb:
Can you run the following commands, and show the output in code wraps?
Code: Select all
df -h
df -i
Code: Select all
service mysqld restart
service mysqld status
tail -100 /var/log/mysqld.logCode: Select all
service mariadb restart
service mariadb status
tail -100 /var/log/mariadb/mariadb.logBe sure to check out our Knowledgebase for helpful articles and solutions!
-
peter.zanetti
- Posts: 90
- Joined: Wed Oct 01, 2014 8:34 am
Re: MySQL database error
We had a one of the unix guys take a look. Took him a while to get the service stopped but once he did that we ran the database_repair script again and that fixed the issue. Thanks