linux新安装mysql后修改root密码以及允许外网访问

2017-04-26

linux新安装mysql后修改root密码以及允许外网访问

直接上代码

mysql -u root -p

enter your password 

use mysql;

update user set password=password('yournewpassword') where user='root';

flush privileges;

grant all on *.* to root@"%" identified by "yourpassword";

flush privileges;

评论
发表评论