Mysql连接报错:1130-host ... is not allowed to connect to this MySql server

作者: 来源:本站原创 点击数: 发布时间:2023年07月12日

连接服务器: mysql -u root -p

看当前所有数据库:show databases;

进入mysql数据库:use mysql;

查看mysql数据库中所有的表:show tables;

查看user表中的数据:select Host, User,Password from user;

修改user表中的Host:update user set Host='%' where User='链接的用户';

最后刷新一下:flush privileges;