首页 > 技术文章 > 远程测试mysql数据库3306端口报错

qlwang 2015-01-30 15:03 原文

错误现象:
[root@localhost ~]# telnet 192.168.10.130 3306
Trying 192.168.10.130...
Connected to 192.168.10.130.
Escape character is '^]'.
GHost '192.168.10.120' is not allowed to connect to this MySQL serverConnection closed by foreign host
解决方法:
具体原因是权限问题,需要重新设置外部登陆用户权限
mysql> grant all privileges on *.* to 'root'@'%' identified by '123456' with grant option;
Query OK, 0 rows affected (0.01 sec)

mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)

mysql> exit

推荐阅读