ubuntu18 安装mysqlserver8

1、添加数据源

如果直接使用命令:

sudo apt install mysql-server。

 此安装mysqlserver为5的版本。 目前mysqlServer8还没有添加到中央源。

如果要安装mysqlServer8,先要配置数据源:(或者直接到官网下载8的安装包)

wget -c https://repo.mysql.com//mysql-apt-config_0.8.14-1_all.deb 

sudo dpkg -i mysql-apt-config_0.8.14-1_all.deb 

2、安装:

sudo apt update
sudo apt install mysql-server

 3、配置开机启动

sudo systemctl status mysql
sudo systemctl enable mysql

 4、登录

mysql -uroot -p123456
原文地址:https://www.cnblogs.com/song27/p/12459697.html