Page 1 of 1

MySQL table keeps getting "crashed"

Posted: Tue Jun 11, 2013 1:43 am
by fogier
In the last couple of weeks is happens multiple times that a table of our Nagios XI server is marked as crashed:

Code: Select all

Jun 11 02:01:01 localhost ndo2db: mysql_error: 'Table './nagios/nagios_logentries' is marked as crashed and last (automatic?) repair failed'
I can repair this with the command "myisamchk -r nagios_servicestatus.MYI" in the directory “/var/lib/mysql/nagios".
What caused this and how can we fix this permanently?

Re: MySQL table keeps getting "crashed"

Posted: Tue Jun 11, 2013 9:33 am
by abrist
Have you run our repair script? http://assets.nagios.com/downloads/nagi ... tabase.pdf
Is machine experiencing frequent power loss or incorrect restarts in vmware?

Re: MySQL table keeps getting "crashed"

Posted: Wed Jun 12, 2013 8:49 am
by fogier
no, we haven't run the script. Will do that and see what happens.
We ran the command

Code: Select all

myisamchk -r nagios_servicestatus.MYI
.

Server has good uptime, no reboots. Don't think that should do it.
Can the backup cause this?

Re: MySQL table keeps getting "crashed"

Posted: Wed Jun 12, 2013 9:37 am
by abrist
Potentially. What version of XI are you running?

Re: MySQL table keeps getting "crashed"

Posted: Thu May 08, 2014 3:18 am
by fogier
I know this one is old and we haven't had the problem since we used a new vm. Topic can be closed.