MySQL installation error nr.1045

Source: Internet
Author: User

When MySQL is installed in windows, the following error occurs: Access denied for user 'root' @ localhost' (using password: no, this problem is because you have installed MySQL on your machine, orAfter the new password is installed and configured this time, the configuration fails due to some reasons such as the problem that the application is stuck or the service is not started. The final result is that the configuration is not successful, the password settings are saved. In this way, after adjusting the service and other reasons, when re-configuring, we will find that an old password input box is added when setting the password. In fact, this is nothing. It is not difficult to enter the old password and reset the password when you know the password. The key is that even if the old password is correct, you still cannot complete the configuration, in the last step, I encountered another error during password authentication. The cause of the error was the password problem, prompting that the old password was incorrect.
 


Solution:
1. Management Tools --- stop the MySQL service in the service.
2. Control Panel --- uninstall MySQL and delete c: \ Program
Files \ mysql directory.
3.This is the most critical step. The password cannot be modified only in the previous two steps, because MySQL still has files, that is, in c: \ Documents and
Settings \ All Users \ Application
The MySQL folder in data. The file is not cleared, which is the root cause of the old password in MySQL reinstallation. Delete the MySQL folder.

4.Check whether the my. ini file exists in the C: \ Windows directory and delete it.
5. Delete heky_local_machine, software, and MySQL in the registry.
 
HKEY_LOCAL_MACHINE \ SYSTEM \ controlset001 \ Services \ Eventlog \ Application \ mysql
Directory Deletion
HKEY_LOCAL_MACHINE \ SYSTEM \ controlset002 \ Services \ Eventlog \ Application \ mysql
Directory Deletion

HKEY_LOCAL_MACHINE \ SYSTEM \ CurrentControlSet \ Services \ Eventlog \ Application \ mysql
Directory Deletion

After completing the preceding steps, you can reinstall MySQL and perform new configuration.

Related Article

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.