1.

mysql> flush privileges;

#授权

2.

mysql> grant all on *.* to root@'localhost' identified by '123';

# 创建用户并授权

 

3.

授权超级用户
grant all on *.* to root@'localhost' identified by '123' with grant option;

 

4. 如何跳过授权

跳过授权表启动mysql
[root@db01 ~]# mysqld_safe --skip-grant-tables --skip-networking &

posted on 2019-05-09 16:58  kaikai2xiaoqi  阅读(112)  评论(0编辑  收藏  举报