您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

mysql远程连接报错问题_MySQL

2024/6/5 5:17:25发布21次查看
bitscn.com
mysql远程连接报错问题
安装完之后成 使用 mysql admin连接报错
error 1130: host ***.***.***.*** is not allowed to connect to this mysql server
以下百度查到的,试过可以
说明所连接的用户帐号没有远程连接的权限,只能在本机(localhost)登录。 
需更改 mysql 数据库里的 user表里的 host项 
把localhost改称%
具体步骤:登陆到mysql 
首先 use mysql; 
按照别人提供的方式update的时候,出现错误。 
mysql> update user set host='%' where user = 'root';
error 1062 (23000): duplicate entry '%-root' for key 'primary'
然后查看了下数据库的host信息如下:
mysql> select host from user where user = 'root'; +-----------------------+ | host | +-----------------------+ | % | | 127.0.0.1 | | localhost.localdomain | +-----------------------+ 3 rows in set (0.00 sec)
host已经有了%这个值,所以直接运行命令:
mysql>flush privileges;
再用mysql administrator连接...成功!!!
bitscn.com
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product