查看当前用户: select user() ;
查看用户的权限: show grants for 'username'@'localhost'
查看当前用户的权限: show grants ;
修改 root 用户的密码
set password for 'root'@'localhost' = password('新密码');
或者:
update user set password = password('newpass') where user = 'root';
flush privileges ;
PRIVILEGES;