How to reset a password in MySQL Windows?

  • Happened? ( Root password recovery on Windows ) - mantigatos
  • no, it did not work out mysql-nt.exe is not an internal or external command - anonymous author
  • What version of mysql? - mantigatos
  • 5.5.23 version - anonymous

2 answers 2

In general, try this

C:\> "C:\Program Files\MySQL\MySQL Server 5.0\bin\mysqld-nt.exe" --defaults-file="C:\\Program Files\\MySQL\\MySQL Server 5.0\\my.ini" --init-file=C:\\mysql-init.txt 

Look for the path to mysql in the service properties

    The second link in Yandex ...

    General principle:

    Stop the mysql server and start with the option --skip-grant-tables --user = root

    Connect:

    mysql -u root Execute commands:

    mysql> UPDATE mysql.user SET Password = PASSWORD ('newpwd') WHERE User = 'root';

    mysql> FLUSH PRIVILEGES;

    Actions in case of using mysql, plesk, windows:

    If you have a client? Or look in psa db in misc table there are mysql_admin and mysql_password values.

    Otherwise you can reset mysql password:

    To reset Mysql admin's pass please follow these steps:

    • Stop Mysql service in Administrative tools -> Services

    • Start -> Run ... -> cmd

    • start it manually using this line: "% plesk_dir% \ Databases \ Mysql \ bin \ mysqld-nt.exe" -P3306 --skip-grant-tables

    • minimize this windows

    • Start -> Run ... -> cmd

    • connect this mysql instance: "% plesk_dir% \ Databases \ Mysql \ bin \ mysql.exe" -P3306 mysql

    • Execute the following query: mysql> update mysql.user set password = password ('new_password') where user = 'admin'; mysql> exit

    • Open Task Manager and terminate mysqld-nt.exe process

    • Start Mysql service from Services window

    After that you can use the Plesk CP -> Databases -> on Mysql

    As a server address, you can use admin / <password you set before>.

    Do not forget to stop the service, then start.

    Need to translate?)))

    • if it wasn’t necessary to translate, then the vehicle could ask Google in the same form) - thunder