设置远程连接mysql

193 阅读1分钟
  • 开启权限

grant all PRIVILEGES on *.* to root@'%' identified by 'myPassword';

flush privileges;

  • 更改密码

update mysql.user set authentication_string=password('123qwe') where user='root' and Host = 'localhost'; flush privileges;