Brief Analysis on modifying the User root Password in mysql

Source: Internet
Author: User


1. to disable a running MySQL instance, manually stop the mysql instance from the management tools service, or enter the doc window in cmd, and enter net stop mysql2. to the installation directory, such as C: \ Program Files \ MySQL Server 5.0 \ bin directory. 3. Enter mysqld-nt -- skip-grant-tables and press Enter. If no prompt is displayed, it is correct. 4. Open another DOS window (because the DOS window can no longer be moved) and go to the mysql \ bin directory. 5. enter mysql Press enter. If success occurs, the MySQL prompt> 6 will appear. connect to the permission database> use mysql; (> is the original prompt, don't forget the last semicolon) 6. change password:> update user set password = password ('000000') where user = 'root'; (don't forget the last semicolon) www.2cto.com 7. refresh permissions (required steps)> flush privileges; 8. exit> quit; 9. log out of the system, log on to MySQL, and log on to MySQL with the username root and the new password 123456. From the column lisa0220

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.