Mysql: optimize all tables in all databases

bschelst/ July 14, 2019/ Linux/ 0 comments

In order to optimize all databases & tables within your mysql instance, you can use the code below. You can also use a more specific script, where only the tables are optimized which have 10MB free space and 10% free space.