1 首先cd / 到根目录,打开mysql控制台 登录数据库 mysql -u root -p
2、授权远程连接
mysql> use mysql; Database changed mysql> grant all privileges on *.* to root@'%' identified by "root"; Query OK, 0 rows affected (0.00 sec)
将权限改为ALL PRIVILEGES
yum install mysql-community-server 来安装server rpm -qi mysql-community-server.x86_64 0:5.6.24-3.el7 systemctl start mysqld 启动 systemctl status mysqld 查看mysql的状态 systemctl stop mysqld 关闭mysql mysql 可以用来查看是否安装成功