查看用户列表
select from host,user,password from mysql.user;
查看授权
show grants for root@localhost;
建用户授权
grant all privileges on . to root@localhost identified by '123456';
删除用户
- delete from mysql.user user='root'
- delete from mysql.user where user='root' and ip='localhost';
来源: http://www.bubuko.com/infodetail-2685220.html