GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   Monitor MySQL servers for crashed tables? (https://gfy.com/showthread.php?t=1150098)

Zeiss 09-15-2014 10:04 AM

Monitor MySQL servers for crashed tables?
 
Is there something to monitor for crashed tables? I just found out one of my sites had a table crashed and had to be repaired. It was like this for about 3 days. :1orglaugh Never happened before. How do I get notified about tables "marked as crashed", so I can repair them? Any ideas of a script to repair the crashed table on detection? :helpme

EDIT: It was INNODB table but it has never happened on InnoDB tables on the same server.

sarettah 09-15-2014 10:35 AM

A couple of years ago I was having an issue with crashed tables. It took about 6 months for the host to find the issue (hardware issue of some sort).

I wrote myself a little monitor script that would go out periodically and do a check on each table and then if it was crashed it would do a repair of the table,

It wasn't real hard to put together.

I am not sure if I still have the code around or not right now.

.

Babaganoosh 09-15-2014 10:46 AM

Not sure if you have access to the MySQL log but if so, just create a script and run it via cron to parse the log for crashed tables.

Zeiss 09-15-2014 04:28 PM

Yea, I have access to everything. It is cisco cloud, quite good. Some server failed last week and had to be moved to other blades. Maybe it is then it happened and I never saw it.

Quote:

create a script and run it via cron to parse the log for crashed tables
and then to notify and repair :thumbsup:thumbsup

Matt 26z 09-15-2014 04:40 PM

What exactly happens to a table that has crashed?

Zeiss 09-15-2014 05:07 PM

Quote:

Originally Posted by Matt 26z (Post 20226525)
What exactly happens to a table that has crashed?

DATE TIME [ERROR] /path/to/mysqld: Table './data_base/tablename' is marked as crashed and should be repaired

woj 09-16-2014 04:47 AM

If you want a custom solution coded, icq: 33375924 or email me at woj#a#t#wojfun#.#c#om to discuss details


All times are GMT -7. The time now is 10:59 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc