1.登录MySQL
mysql -u root -p
2.选择数据库
use mysql;
3.查询所有用户
select user,host from user;
4.更新root用户权限
update user set host="%" where user="root";
5.刷新权限
flush privileges;
1.登录MySQL
mysql -u root -p
2.选择数据库
use mysql;
3.查询所有用户
select user,host from user;
4.更新root用户权限
update user set host="%" where user="root";
5.刷新权限
flush privileges;