2 messages in com.mysql.lists.bugsRe: Corupt Table
FromSent OnAttachments
Scott Adams15 Sep 2000 05:40 
Michael Widenius15 Sep 2000 10:10 
Subject:Re: Corupt Table
From:Scott Adams (sco@jeanharris.com)
Date:09/15/2000 05:40:27 AM
List:com.mysql.lists.bugs

We'll it happened again. About 8 hours later. I have the last good data and index file if anyone wants them.

Here is what I think is happening. I watched the processlist on and off up until this happened. It seemed like things were running fine until all off a sudden ever select to the table would lock for 30, 40 up to 300 seconds. Obviously too long when this select returns results in 2 seconds normally.

Also during this time I checked extended-status watching not-flushed-delay-key-writes. It stayed at 0 all night right thru most of our peak times. Then, when the Locks starting happening, I looked at it and the not-flushed-delay-key-writes was at >800. I let it run over night and that number was no different when I got up this morning.

I think the delay-key-write is not working write under heavy load. I'm disabling that as I bring my server back up soon. We'll see if that makes a difference.

Any one have similar problems? Mysql developers: could there be a bug with delay-key-write? Like I said above, I have the table before it got corupted and an update log up to that point.

Thanks, Scott

----- Original Message ----- From: "Steve Ruby" <ste@rubysolutions.com> To: <sco@jeanharris.com> Sent: Thursday, September 14, 2000 5:03 PM Subject: Re: Corupt Table

If the server was running while you ran that and the table had not been flushed then there is a good chance (especially under high-access) that there is nothing wrong with the table. But due to unflushed key buffers and such the table on disk doens't mach what is partly in memory.

If you must run myisamchk while the server is running you should go into mysql client program, run flush tables; lock table blah write;

that will stop the table from being opened by the server while you are checking it.. for this reason CHECK TABLE is Much better.

Scott Adams wrote:

Yes, it was running. I'll try the check from with the client.

----- Original Message ----- From: "Steve Ruby" <ste@rubysolutions.com> To: "Scott Adams" <sco@jeanharris.com> Cc: <mys@lists.mysql.com> Sent: Thursday, September 14, 2000 4:57 PM Subject: Re: Corupt Table

Is the server running when you did myisamchk? That first line (I believe) should only happen if the server is still running or crashed before you ran myisamchk. If the server is still running youshould try running CHECK TABLE sql query from within the mysql monitor rather than myisamchk or stop the server before running myisamchk.

Scott Adams wrote:

Hello:

I emailed earlier about Locked in the processlist. It seems that my

Hits index is getting corupted easily. Any suggestions to stop this? Below is the output of myisamchk.

Scott

[root@web1 CTP]# myisamchk Hits.MYI Checking MyISAM file: Hits.MYI Data records: 2960032 Deleted blocks: 0 myisamchk: warning: 1 clients is using or hasn't closed the table properly - check file-size myisamchk: warning: Size of datafile is: 469968400 Should be: 469909252 - check key delete-chain - check record delete-chain - check index reference - check data record references index: 1 - check data record references index: 2

- check data record references index: 3 myisamchk: error: Found 2959989 keys of 2960032 - check record links myisamchk: error: Record-count is not ok; is 2960394 Should be: 2960032 myisamchk: warning: Found 2960394 parts Should be:

2960032 parts