忘记密码修改密码的步骤:
确保mysql服务已经打开
然后,打开cmd输入:
mysqld --console --skip-grant-tables --shared-memory
mysql -uroot -p #无需输入密码,直接回车即可
update mysql.user set authentication_string='' where user='root';
alter user'root'@'localhost' identified by '新密码'
忘记密码修改密码的步骤:
确保mysql服务已经打开
然后,打开cmd输入:
mysqld --console --skip-grant-tables --shared-memory
mysql -uroot -p #无需输入密码,直接回车即可
update mysql.user set authentication_string='' where user='root';
alter user'root'@'localhost' identified by '新密码'