更新mysql 的账号密码
blank
blank
发布于 2019-04-09 / 393 阅读 / 0 评论 / 0 点赞

更新mysql 的账号密码

登陆一个有权限的管理员账号如root

# mysql -uroot -p

如 将所有host的 root 用户的密码改为 123456

mysql> update mysql.user set authentication_string=password('123456') where user='root';

刷新权限后生效

mysql> flush privileges;

评论