Navicat for MySQL connection error, error code 1045 Solution

Source: Internet
Author: User

Navicat for MySQL connection error, error code 1045 Solution

Navicat for MySQL

Solution: reset the root user password.

Method 1:

Open "start" -- "program" -- "MySQL" -- "MySQL 5.0" -- "MySQL Server Instance Config Wizard" and click "Next ".

Current root password: Enter the original password

New root password: Enter the New password

Confirm: Enter the new password again.

Next, you can proceed all the way... until it is successful!

Error 1045 is essentially a password issue! If you use a blank password for the first login, you can leave it empty.

Method 2:

1. log on to the system as a system administrator;

2. If the MySQL server is running, stop it.

If the server runs as a Windows Service, go to Service Manager: Start Menu-> Control Panel-> Administrative Tools-> services

If the server is not running as a service, you may need to use the task manager to force it to stop.

3. Create a text file and place the following commands in a single line:

Set password for 'root' @ 'localhost' = PASSWORD ('mynewpassword ');

Save the file with any name. In this example, the file is C: \ mysql-init.txt.

4. Enter the doscommand prompt: Start Menu-> Run-> cmd

Assume that you have installed MySQL to C: \ mysql. If you install MySQL in another location, adjust the following commands.

Run the following command at the doscommand prompt:

C: \> C: \ mysql \ bin \ mysqld-nt -- init-file = C: \ mysql-init.txt

When the server is started, run the "-- init-file" option (function: Read SQL commands from the specified file at startup) to change the root user password. When the server is successfully started, delete the C: \ mysql-init.txt.

5. Stop the MySQL server and restart it in normal mode. If you run the server as a service, you should start it from the Windows service window. If the server is started manually, the command can be used as usual.

This article permanently updates the link address:

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.