If you ever want to repair/optimize all databases on your cPanel server (this also works on non-cPanel servers by the way) all you have to do is run this:
- Repair all databases:
mysqlcheck –all-databases -r
- Optimize all databases:
mysqlcheck –all-databases -o