update user set host = '%' where user = 'root';SELECT host, user FROM user;
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' WITH GRANT OPTION; 123456为密码
FLUSH PRIVILEGES;
update user set host = '%' where user = 'root';SELECT host, user FROM user;
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY '123456' WITH GRANT OPTION; 123456为密码
FLUSH PRIVILEGES;