mysql5.7.26安装
tar -xf mysql-5.7.26-1.el7.x86_64.rpm-bundle.tar
yum -y install mysql-comm* (备注:yum install -y mysql-community-common-5.7.26-1.el7.x86_64.rpm mysql-community-server-5.7.26-1.el7.x86_64.rpm mysql-community-client-5.7.26-1.el7.x86_64.rpm mysql-community-libs-5.7.26-1.el7.x86_64.rpm 安装这几个也可以)
systemctl start mysqld
systemctl enable mysqld
systemctl status mysqld
grep -i 'password' /var/log/mysqld.log
mysql -u root -p''
set global validate_password_policy=0;
set global validate_password_length=6;
alter user root@localhost identified by "123456";
mysql -uroot -p123456
show databases;
GRANT ALL PRIVILEGES ON *.* TO root@"%" IDENTIFIED BY "123456"; 设置root用户的远程连接密码
mysqldump -uroot -p123456 -A >all.sql
mysqldump -uroot -p123456 --all-databases >all2.sql
mysql -uroot -p123456 <all.sql