Command for resetting the mysql password in Windows _ MySQL
Source: Internet
Author: User
In Windows, run the bitsCN.com command to reset the mysql password. Local Environment: Windows XP and xampp integrated environment.
Xampp installation directory: d:/xampp
1. stop the running MySQL process
> Net stop mysql
If it is not loaded as a service, you can directly close it in the process manager or service.
2. start MySQL in safe mode
Go to the mysql directory and run it in the command line.
> D:
> Cd xampp/mysql/bin
> Mysqld.exe -- skip-grant-tables
3. you will be able to access MySQL without a password.
> Mysql-u root-p
Enter the password and press enter.
4. change the password
> Use mysql
> Update user set Password = password ('New password') where User = 'root ';
> Flush privileges;
5. start the MySQL service
Close all MySQL processes in the Task Manager and start them with the following command.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service