MySQL 5.1 does not support the statements
CHECK TABLE, OPTIMIZE
TABLE, ANALYZE TABLE, or
REPAIR TABLE for partitioned tables. However,
there are alternatives available for performing partitioning
maintenance tasks.
Beginning with MySQL 5.1.5, you can rebuild partitions using
ALTER TABLE ... REBUILD PARTITION, which has
the same effect as dropping all records stored in the partition,
then reinserting them. This can be useful for purposes of
defragmentation. You can rebuild a one or more partitions
belonging to the same table at one time using this statement, as
shown in these examples:
ALTER TABLE t1 REBUILD PARTITION p1; ALTER TABLE t1 REBUILD PARTITION p0, p2;
Executing the first statement rebuilds the partition named
p1 from the table t1.
Performing the second statement rebuilds partitions
p0 and p2 from table
t1.
ALTER TABLE ... REORGANIZE PARTITION also
causes partition files to be rebuilt.
The statements ANALYZE PARTITION,
CHECK PARTITION, OPTIMIZE
PARTITION, and REPAIR PARTITION
— intended to, respectively, analyze, check, optimize,
and repair individual or multiple partitions — were
supported beginning with MySQL 5.1.5 and then removed in MySQL
5.1.24. (Bug#20129)
The use of mysqlcheck or myisamchk is also not supported with partitioned tables.

User Comments
Add your own comment.