MySQL – Repair a corrupt or invalid table

--> (Word) --> (PDF) --> (Epub) --> (Text)
--> (XML) --> (OpenOffice) --> (XPS)

This article will go over the steps of repairing a corrupt or invalid MySQL [gs table]. Common errors you may see are:

  • Log into the MySQL server via SSH;
  • At the shell prompt type:
mysqlcheck --auto-repair [database name] 
  • The [gs utility] will automatically check and repair all tables in the [gs database] specified and report its results;

If the above utility does not work you can try the following at the shell prompt (Linux only):

cd /var/lib/mysql/[database name]
myisamchk -r *.MYI

What is an MYI?

Index of a MyISAM table created within a MySQL [gs database]; defines the structure of the table and includes a counter in the header that shows whether or not the table has been closed properly.

MyISAM is the default storage engine used by MySQL. It manages non-transactional tables and provides high-speed data storage and retrieval operations.

SOURCE

LINK (Hosting.com)

LANGUAGE
ENGLISH