修改密码
ALTER USER 'YourUserName'@'%' IDENTIFIED BY 'YourPassword;
FLUSH PRIVILEGES;
允许IP访问
use mysql;
select user,host from user;
update user set host = '%' where user = 'root';
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
flush privileges;
ALTER USER 'YourUserName'@'%' IDENTIFIED BY 'YourPassword;
FLUSH PRIVILEGES;
use mysql;
select user,host from user;
update user set host = '%' where user = 'root';
GRANT ALL PRIVILEGES ON *.* TO 'root'@'%';
flush privileges;