Host is not allowed to connect to this MySQL server错误的解决办法
来源:互联网 发布:自学编程网站有哪些 编辑:程序博客网 时间:2024/06/06 01:12
错误描述
我先做了这些工作:服务器用的 Windows Server 2012。配置好服务器上的MySQL。防火墙允许mysqld.exe 。
然后在我自己的电脑上用 workbench 连接服务器上的 MySQL 发现无法连接。提示错误: Host ‘xxx.xxx.xxx.xxx’ is not allowed to connect to this MySQL server 。其中 ‘xxx.xxx.xxx.xxx’ 是我自己的电脑的IP。
解决方法
远程桌面连接到服务器。调用 mysql -u root -p
命令打开客户端,连接数据库。执行如下命令并得到返回结果:
mysql> use mysqlmysql> select t.host from user t where t.user='root';+--------------+| host |+--------------+| localhost |+--------------+
这个返回结果说明现在 root 用户只允许在服务器的本地登录。
执行如下命令:
update user set host='%' where user='root';
然后重启 MySQL 服务就可以了。
原文地址
0 0
- Host is not allowed to connect to this MySQL server错误的解决办法
- Host 'thinkive-PC' is not allowed to connect to this MySQL server错误解决办法
- "Host 'localhost' is not allowed to connect to this MySQL server" 的原因及解决办法
- "Host 'localhost' is not allowed to connect to this MySQL server" 的原因及解决办法
- "Host 'localhost' is not allowed to connect to this MySQL server" 的原因及解决办法
- host is not allowed to connect to this MySQL server
- Host is not allowed to connect to this MySQL server
- host ... is not allowed to connect to this MySql server
- Host * is not allowed to connect to this MySQL server
- host is not allowed to connect to this MySql server
- Host is not allowed to connect to this MySQL server
- host ... is not allowed to connect to this MySql server
- Host '***' is not allowed to connect to this MySQL server"
- host ... is not allowed to connect to this MySql server
- Host is not allowed to connect to this mysql server,
- Host '***' is not allowed to connect to this MySQL server
- mysql数据库 message from server: "Host is not allowed to connect to this MySQL server"解决办法
- message from server: "Host is not allowed to connect to this MySQL server"解决办法
- 单片机项目:驱动VS1003模块(二)
- JS dataTransfer 对象在拖拽中的使用
- 23 广播服务结合音乐Demo5
- 多个串公共子串算法
- loopback学习(5)--扩展API
- Host is not allowed to connect to this MySQL server错误的解决办法
- Linux系统的在线求助 man page 与 info page
- MySQL数据类型 BLOB和TEXT
- $.type()的用法
- hdu 1166 敌兵布阵 线段树
- day15 python css
- mongodb副本集和分片部署
- 图之 宽度优先遍历 DFS 邻接矩阵建立的图
- 23 服务IntentService Demo6