Automatically optimize all tables in a MySQL database


Use this script preferably with a cronjob to automatically optimize all the tables in your mysql databases. Under root privilleges the script will search for all the databases in your server and will optimize them all. Hope you will like it as it took me more than 3 hours to write it 🙂


Optimize all databases/tables in MySQL
For more tutorials you can refer here


17 responses »

  1. mysqlcheck is a little slow, but the most important is that it can break tables that have unicode charsets.

    Anyway this script optimizes only tables that want optimization, while the mysqlcheck optimizes everything.

  2. Pingback: Dr. Mikes Blog » Optimize MySQL

  3. Pingback: Optimize MySQL « Dr. Mike’s Blog

  4. Pingback: Web 2.0 Announcer

  5. Pingback: tending the garden » links for 2007-06-14

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s