is not allowed to connect tothis mmysql server

发现在linux中配置完mysql

开放完端口出现这个问题  

首先在linux中登录MySQL

is not allowed to connect tothis mmysql server

然后输入  use mysql;

is not allowed to connect tothis mmysql server

 

mysql> select host from user where user='root';

is not allowed to connect tothis mmysql server

输入以上两个命令查看主机配置信息

 

 

 

执行 update user set host = '%' where user ='root';

将host设置为通配符模式%    Host设置“%”便可远程访问了

 

is not allowed to connect tothis mmysql server

is not allowed to connect tothis mmysql server

最后执行  flush privileges;  是更改的配置立即生效

 is not allowed to connect tothis mmysql server

 

相关文章:

  • 2021-05-11
  • 2022-01-10
  • 2021-09-27
  • 2021-04-12
  • 2021-08-29
  • 2021-10-24
  • 2021-08-02
  • 2022-12-23
猜你喜欢
  • 2021-05-30
  • 2022-12-23
  • 2021-08-04
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案