链接:https://pan.baidu.com/s/1lc5ctVyp7kXXZXCsh9AiRA?pwd=yyds
提取码:yyds
官网链接
具体下载步骤可见我另一篇单独写的下载mysql下载博客 跳转链接
yum install perl net-tools -y
rpm -qa | grep mariadb
rpm -e --nodeps mariadb-libs-5.5.60-1.el7_5.x86_64
tar -xvf mysql-8.0.18-1.el7.x86_64.rpm-bundle.tar
rpm -ivh mysql-community-common-8.0.18-1.el7.x86_64.rpm
rpm -ivh mysql-community-libs-8.0.18-1.el7.x86_64.rpm
rpm -ivh mysql-community-client-8.0.18-1.el7.x86_64.rpm
rpm -ivh mysql-community-server-8.0.18-1.el7.x86_64.rpm
systemctl start mysqld
cat /var/log/mysqld.log | grep password
mysql -u root -p
输入刚生成的mysql随机密码
set global validate_password.policy=LOW;
set global validate_password.length=6;
ALTER USER 'root'@'localhost' IDENTIFIED BY '123456' PASSWORD EXPIRE NEVER;
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '123456';
FLUSH PRIVILEGES;
use mysql;
update user set host='%' where user = 'root';
commit;
exit;
systemctl restart mysqld;