1 Using MySQLTuner
You can download the MySQLTuner script as follows:
wget http://mysqltuner.com/mysqltuner.pl
In order to run it, we must make it executable:
chmod +x mysqltuner.pl
Afterwards, we can run it. You need your MySQL root password for it:
./mysqltuner.pl
server1:~# ./mysqltuner.pl