‘Host’ is not allowed to connect to this mysql server

冷暖自知 提交于 2020-03-02 03:04:05

‘Host’ is not allowed to  connect to this mysql server

        mysql 数据库不允许远程连接

 

方法一:修改 host 表

       进入mysql数据库,选择mysql 

mysql> use mysql;

   选择 host 表

mysql> select host from user;

   更新 host, 然后退出。

mysql> update user set host = '%' where user='root';

    重启数据库, 完成。

# service mysqld restart

    

 

 --------------  打赏码  --------------------------------    

 

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!