mysql 允许远程连接

开启远程链接

update user set host = "%" where user = "root";

flush privileges;

关闭远程链接

update user set host = "localhost" where user = "root" and host= "%";

flush privileges;

原文地址:https://www.cnblogs.com/happen-/p/6927601.html