mysql权限

来源:互联网 发布:淘宝不开店能卖东西吗 编辑:程序博客网 时间:2024/04/28 09:09
  • 开启远程连接权限

grant all on *.* to root@'%' indentified by 'passwd'

grant select, insert, update, delete on *.* to root@localhost identified by 'passwd'

  • 查看权限

show grants for root;

show grants for root@'localhost';

select user, host, select_priv from mysql.user;

  • 新增用户

create user suren@localhost identified by 'suren'

  • 删除用户

drop user suren

 

查看原文:http://surenpi.com/2014/09/02/%e8%a7%a3%e5%86%b3mysql/

0 0