MySQLパスワードリセット方法(Windowsで)


ここではmysql 5.バージョン7を例に
1、  mysql:     cmd     net stop mysql57

2、    cmd     mysqld --defaults-file="C:\ProgramData\MySQL\MySQL Server 5.7\my.ini" --skip-grant-tables   ---    (         )

3、     cmd     mysql -uroot -p              ,    (      )

4、     :use mysql;

5、  root   :update user set authentication_string=password('   ') where user='root' and Host='localhost';

6、    :flush privileges;

7、  :quit

8、    :mysql -uroot -p             ,          。  !!!