赞
踩
1、安装mysql8
sudo apt install mysql-server
sudo mysql -u root -p
set global validate_password_policy=LOW;
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password by '123456';
update user set host = '%' where user ='root';
flush privileges;
2、修改mysql的配置文件
cd /etc/mysql/
修改my.cnf文件
增加两行
bind-address = 0.0.0.0
mysqlx-bind-address = 0.0.0.0
3、开机自启动并重启mysql
sudo systemctl enable mysql
sudo systemctl restart mysql
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。