Debian 9-install MySQL Server
The steps below would show you what to install whichever version of Mysql-server your want on your Debian 9 server and why Yo U should not just runsudo apt install mysql-server -y
Similar Posts
- Debian 8-install MySQL 5.7
Steps
Usually, to install MySQL in a distro, you would just perform the following commands:
sudo apt Update sudo Install mysql-server-y
You would then receive either MySQL 5.5, 5.6, or 5.7 depending on which distro you were using, but they were all versions of MySQL. However, with Debian 9, if-do-this-you-'ll end up installing MariaDB 10.1 which are a drop in replacement for 5.6.
If you decide to just go with MariaDB 10.1 and is confused by the lack of a prompt to set the root password, just login W ITH and then use sudo mysql
mysql command to set the password:GRANT ALL ON *.* TO [email protected] identified by ‘myawesomepassword‘;
Install MySQL 5.6, 5.7, or 5.8-preview
If you really want MySQL instead of MariaDB for whatever reason, you can execute the script below to install the version y ou want.
#!/bin//tmpwget https://dev.mysql.com/get/mysql-apt-config_0.8.7-1_ All.debsudo dpkg-i mysql-apt-config_*.deb
At the Popup-page, select the version of you want.
Then use the following commands to install the MySQL server (it'll install the version you selected).
sudo apt Update sudo Install mysql-community-server-y
References
- Programster ' s Blog-debian 8-install MySQL 5.6
- Mysql.com-download MySQL APT Repository
[Go]debian9 Install any version of MySQL