sudo cat /etc/mysql/debian.cnf
里面的就是用户和密码,登录进去修改其他用户密码就行
- 连接到mysql数据库
- 修改密码123456是密码
use mysql;
update mysql.user set authentication_string=password('123456') where user='root' and Host ='localhost';
update user set plugin="mysql_native_password";
flush privileges;
quit;