$ sudo apt-get install mysql-server
$ mysql_secure_installation
$ sudo mysql -u root -p
mysql> drop user 'root'@'localhost';
mysql> create user 'root'@'%' identified by 'your_pass';
mysql> grant all privileges on *.* to 'root'@'%' with grant option;
mysql> flush privileges;
mysql> exit;