密码重置
可以跳过密码
或者使用命令行
重置用户密码
-- 方式 1
ALTER USER 'root'@'%' IDENTIFIED WITH mysql_native_password BY 'new_password';
ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'new_password';
-- 方式 2 (推荐)
FLUSH PRIVILEGES;
SET PASSWORD FOR 'root'@'localhost' = PASSWORD('new_password');
SET PASSWORD FOR 'root'@'%' = PASSWORD('new_password');