MySQL table keeps getting "crashed"

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
fogier
Posts: 66
Joined: Fri Jul 13, 2012 12:53 am

MySQL table keeps getting "crashed"

Post 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?
Last edited by fogier on Thu May 08, 2014 3:19 am, edited 1 time in total.
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: MySQL table keeps getting "crashed"

Post 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?
Former 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.
fogier
Posts: 66
Joined: Fri Jul 13, 2012 12:53 am

Re: MySQL table keeps getting "crashed"

Post 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?
abrist
Red Shirt
Posts: 8334
Joined: Thu Nov 15, 2012 1:20 pm

Re: MySQL table keeps getting "crashed"

Post by abrist »

Potentially. What version of XI are you running?
Former 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.
fogier
Posts: 66
Joined: Fri Jul 13, 2012 12:53 am

Re: MySQL table keeps getting "crashed"

Post 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.
Locked