Optimize MySQL Table

Last updated: March 28, 2011

MySQL Optimize Table will de-fragment a mysql table and is helpful for tables that are frequently modified.

Backup First

[root@host /]# mysqldump user_database > user_database.sql

Then Optimize

[root@host /]# mysql

mysql> optimize table thetable;

Tags: mysql, optimize table