错误代码是1130,ERROR 1130: Host xxx.xxx.xxx.xxx is not allowed to connect to this MySQL server 是无法给远程连接的用户权限问题

错误代码是1130,ERROR 1130: Host xxx.xxx.xxx.xxx is not allowed to connect to this MySQL server 是无法给远程连接的用户权限问题 

 

首选语法为: 
Sql代码 
GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'%' IDENTIFIED BY 'mypassword' WITH GRANT OPTION; 

示例: 
Sql代码 
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' WITH GRANT OPTION; 

执行完后,再 
mysql:flush privileges; 
刷新一下权限就可以了,不用重启 

posted @ 2017-06-27 10:52  StriveSun  阅读(231)  评论(0编辑  收藏  举报