wget https://dev.mysql.com/get/mysql-apt-config_0.8.9-1_all.deb
dpkg -i mysql-apt-config_0.8.9-1_all.deb
You will be asked to select product and version that you want to install. In the first step, select Server and next select either mysql-5.6 or mysql-5.7. Then click Apply.
apt-get update
apt-get install mysql-server
/etc/init.d/mysql restart mysql_upgrade -u<user> -p
sudo apt-get remove --purge mysql\*
sudo apt-get install software-properties-common sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xcbcb082a1bb943db sudo add-apt-repository 'deb [arch=amd64,i386,ppc64el] http://www.ftp.saix.net/DB/mariadb/repo/10.1/debian jessie main'
sudo apt-get update sudo apt-get install mariadb-server
apt-get install phpmyadmin
/etc/init.d/mysql restart mysql-upgrade
wget https://github.com/major/MySQLTuner-perl/tarball/master tar xf master cd major-MySQLTuner-perl-993bc18/ ./mysqltuner.pl