Skip to main content

Bulk optimization of Mysql tables



Fragmented mysql databases are known to slow down the mysql server. And these bases need to be sometimes optimized: to defragment.

There are two ways to optimize tables with the mysqlcheck utility. The first:


  mysqlcheck -Ao 

Here: key A checks tables for errors, and key o performs optimization.

The second way:

  mysqloptimize -A 

The value of the keys here is the same. :)




How do you rate the article?
Звёзд: 1Звёзд: 2Звёзд: 3Звёзд: 4Звёзд: 5 (No ratings yet)
Loading...

” 2 Comments “ Mass Optimizing Mysql Tables

  1. Sometimes (for example in ubunt) you may need to specify the name / password explicitly
    something like: mysqlcheck —user = username —password = password -Ao

    1. Yeah, I missed that moment. I have a .my.cnf file in my root folder where my mysql root password is registered. And the password is not requested. :)

Add a comment

Your email will not be published.