[Imc-tech] more on site problems:

Daniel S. Lewart lewart at uiuc.edu
Sat May 14 00:16:57 CDT 2005


Mike, Sascha, et al,

> it appears that the problem only exists when one's logged in as an
> administrator.  here's the error:
> Can't open file: 'articles.MYI'. (errno: 145)

That was the final clue I needed.  Each time Mike reported this error
I checked the website and everything looked fine to me,
so I thought it was just a transient problem.

Reading 5.8.3 MySQL Table Maintenance and Crash Recovery:
	http://dev.mysql.com/doc/mysql/en/table-maintenance.html
reminds us of the following ...

The MySQL ucimc.articles table corresponds to three files:
   * /var/lib/mysql/ucimc/articles.frm - Definition (format) file
   * /var/lib/mysql/ucimc/articles.MYD - Data file
   * /var/lib/mysql/ucimc/articles.MYI - Index file

MySQL (errno: 145) means "Table was marked as crashed and should be repaired".
The MYD and MYI files had timestamps from early Thu morning, as shown below.

Below is a transcript of what I did to repair the articles table.

Deja vu all over again:
   http://lists.chambana.net/mailman/archive/imc-web/2004-September/000728.html

Perhaps I should have used "CHECK TABLE" and "REPAIR TABLE" instead.

Cheers,
Dan
------------------------------------------------------------------
# cd /var/lib/mysql
# ls -l ucimc/articles.MYD ucimc/articles.MYI
-rw-rw----  1 mysql mysql 91137472 May 12 05:07 ucimc/articles.MYD
-rw-rw----  1 mysql mysql 74593280 May 12 05:56 ucimc/articles.MYI
------------------------------------------------------------------
# myisamchk ucimc/articles
Checking MyISAM file: ucimc/articles
Data records:   25699   Deleted blocks:       0
myisamchk: warning: Table is marked as crashed
- check file-size
- check record delete-chain
- check key delete-chain
- check index reference
- check data record references index: 1
- check data record references index: 2
- check data record references index: 3
- check data record references index: 4
- check data record references index: 5
- check record links
MyISAM-table 'ucimc/articles' is usable but should be fixed
------------------------------------------------------------------
# myisamchk -r ucimc/articles
- recovering (with sort) MyISAM-table 'ucimc/articles'
Data records: 25699
- Fixing index 1
- Fixing index 2
- Fixing index 3
- Fixing index 4
- Fixing index 5
-------------------------------------------------------------------


More information about the Imc-tech mailing list