# Does OPTIMIZE TABLE do a CHECK and REPAIR

**URL:** <https://forums.percona.com/t/does-optimize-table-do-a-check-and-repair/1071>\
**Category:** Other MySQL® Questions\
**Created:** [February 2, 2009, 2:12pm UTC](https://forums.percona.com/t/does-optimize-table-do-a-check-and-repair/1071 "2009-02-02T14:12:30Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![thiru](https://avatars.discourse-cdn.com/v4/letter/t/b9e5f3/32.png) [@thiru](https://forums.percona.com/u/thiru)\
**Post date:** [February 2, 2009, 2:12pm UTC](https://forums.percona.com/t/does-optimize-table-do-a-check-and-repair/1071/1 "2009-02-02T14:12:30Z")

</div>

Apart from its optimization activities, does OPTIMIZE TABLE also CHECK the tables for corruptions and REPAIR the corrupted ones? The OPTIMIZE TABLE documentation ([URL][http://dev.mysql.com/doc/refman/5.0/en/optimize-table.html[/URL]](http://dev.mysql.com/doc/refman/5.0/en/optimize-table.html%5B/URL%5D)) isn’t very clear about this.

Currently i’m running a periodic OPTIMIZE TABLE and i’m wondering if i should replace that with “mysqlcheck -Aao –auto-repair”.

Appreciate you time. Thanks.

-Thiru

---

<div class="post-metadata">

**Author:** ![xaprb](https://avatars.discourse-cdn.com/v4/letter/x/49beb7/32.png) [@xaprb](https://forums.percona.com/u/xaprb)\
**Post date:** [December 25, 2009, 10:17am UTC](https://forums.percona.com/t/does-optimize-table-do-a-check-and-repair/1071/2 "2009-12-25T10:17:37Z")

</div>

It is engine-specific. What storage engine?
