MySQL Error: Can’t perform query: Can’t open file: ‘xxxx.MYI’ (errno: 145)

I have timesheet.php and bugzilla 2.20 running on a linux box sharing same mysql db server.

When I tried logging-in to both the applications, I got following error.

Can't perform query: Can't open file: 'xxxxxx.MYI' (errno: 145)

You will face this error when your MySQL table is corrupted, and there are a few reasons for that:
1 – Server crash;
2 – Hardware failure;
3 – A MySQL write process was interrupted;

However you can fix this very easy with a simple query…

$ mysql
mysql> use database_name;
mysql> REPAIR TABLE table_name;

This will repair the specified table. The name of the table which is corrupted can be seen in the error as ‘xxxxx.MYI’.

Good luck.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: