开发者

MySQL Corruption After Graceful Restart [closed]

开发者 https://www.devze.com 2022-12-21 04:48 出处:网络
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.

This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.

Closed 7 months ago.

Impro开发者_运维问答ve this question

Has anyone ever encountered MySQL corruption after performing a graceful server reboot?

Just worries me because I have never had that happen before. What could be the causes?


Index changes to MyISAM tables are not immediately flushed to disk for performance reasons. If your MySQL server is killed before the indexes are completely flushed to disk, then there is an inconsistency between the data (which is flushed asap) and the indexes. In this case, myisamchk in repair mode can fix the indexes (which is pretty much the same as REPAIR table, but is more flexible in the amount of memory it uses and hence its speed).


MyISAM is infamous for it, especially in older versions. This also affects all other engines, all engines use MyISAM to store their table information (information schema uses MyISAM).

The cause is unknown, it's a very old bug. You could try REPAIR, a work around created for this problem.

Good luck!

0

精彩评论

暂无评论...
验证码 换一张
取 消