如果连接mySQL的时候出现'Host "WIN-S'IP0AB0UC68 is not allowed to connect to this MySQL server的类似错误,请试着使用下面的解决方案:
方案一:
-- 进入mysql,执行以下语句('root'是用户名,'123456'是密码)
use mysql;
grant all privileges on *.* to root@"%" identified by '123456' with grant option;
方案二(推荐):
use mysql;
update user set host='%' where user='root';
flush privileges;
如果以上语句解决不了问题,就试试下面这句:
grant all on *.* to p" Identified by "123456";
这句的含义是,授权客户端ip,可以使用用户名root,密码126456访问本服务器