访问远程服务器上的Mysql数据库连接是报:1130-host is not allowed to connect this MYSQL severe;

 解决方案:

登录远程服务器下的mysql下。

 

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

 Query OK, 1 row affected (0.00 sec)
Rows matched: 1  Changed: 1  Warnings: 0
mysql> flush privileges;
Query OK, 0 rows affected (0.01 sec)
mysql> quit­

 

其中flush privileges 必须要执行,mysql 新设置用户或更改密码后需用flush privileges刷新MySQL的系统权限相关表,否则会出现拒绝访问,还有一种方法,就是重新启动mysql服务器,说白了就是设置完刷新下系统,来使新设置生效。

 

相关文章:

  • 2022-12-23
  • 2021-04-24
  • 2021-12-23
  • 2021-06-04
  • 2022-01-08
  • 2021-08-16
  • 2021-09-25
猜你喜欢
  • 2021-08-27
  • 2022-12-23
  • 2021-04-01
  • 2021-09-10
  • 2021-08-09
  • 2021-08-25
  • 2021-12-27
相关资源
相似解决方案