ERROR 2003 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061)

I have installed MySQL version 5.6 on windows 7. My Installation was successful and without any error. I received “ERROR 2003 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061)” while I was trying to start MySQL server from command prompt. I am attaching the screen shot of the error I received.

mysql u root p mysql ERROR 2003 (HY000): Cant connect to MySQL server on localhost (10061)
Starting MySQL From Command Prompt

When I could not connect to MySQL server installed on my windows. I tried to connect MySQL Server directly by using “MySQL5.6 Command Line Client”. Same error was occurring and MySQL Command line was disappearing.

I was little worried of this error – ERROR 2003 (HY000). I did not get any of issues while installing MySQL5.6 on windows so MySQL server should work properly.
I did search on internet (MySQL forum, DB related forums) and I resolved Can’t connect to MySQL server on ‘localhost’ (10061) error. Now I was able to run MySQL server from command prompt.

Reason for ERROR 2003 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061) – MySQL services has not been started.

Please see the steps below to fix this problem.

1. Please Log in as Admin to your System.
2. Open your Task Manager panel.
3. Go to Services tab.
4. See there for MySQL presence. It will look like this image given below.In my case it is displayed like MySQL56.

mysqlTaskManagerImage ERROR 2003 (HY000): Cant connect to MySQL server on localhost (10061)
Showing MySQL Services Status using Task Manager

In the above image you can see that MySQL56 service is showing as Stopped. Please see the blue dark line in the image.

5. Please select MySQL56 and do right click. You will get Start option. Select Start command to start MySQL Services. Please see the below image for your reference.

mysqlmanuallystart ERROR 2003 (HY000): Cant connect to MySQL server on localhost (10061)
Image Showing how to start MySQL server from task manager

6. Please recheck that MySQL service has been started successfully.
7. In case MySQL services do not start using this way, It means you are not logged in with Admin account. In this case you will receive this error.

AccessDeniedError ERROR 2003 (HY000): Cant connect to MySQL server on localhost (10061)
Getting Error if not logged in as Admin

Please follow next given steps to start MySQL service from Administrative Panel.
8. Please Go to  Control Panel > All Control Panel Items > Administrative Tools.
9. Please go to Services. Below image is showing the process.

AdminPanelScreen ERROR 2003 (HY000): Cant connect to MySQL server on localhost (10061)
Image showing Services in Administrative Tools

10. Please select MySQL56 under Name column.
11. Please click on start link from left panel to start MySQL Service. Please see the image below for your refrence.

MySQLServicesFromAdminstrativePanel ERROR 2003 (HY000): Cant connect to MySQL server on localhost (10061)
Starting MySQL server from Administrative panel

12. Once MySQL service started. Please go to MySQL bin directory using command prompt and retype the command >mysql -u root -p mysql
13. Please enter your MySQL password.
14. We can see image given below after MySQL server started successfully.

MysqlStartedSuccessfully ERROR 2003 (HY000): Cant connect to MySQL server on localhost (10061)
MySQL Server Started Successfully from Command prompt

Thanks for reading this post. Please let me know if your problem has been resolved.

Share this post:

Recent Posts

3 Comments

  1. Avatar for Tarun Singh
    rutwik says:

    thankyou very much for your visual feedback

  2. Avatar for Tarun Singh
    Ben says:

    Thank you Tarun. An excellent explanation of how to solve the problem.

  3. Avatar for Tarun Singh
    Sunnu PS says:

    Was working on this problem for 1 hour (at least !) when I fall on your explanation. Now it works like magic. Thanks a lot !

Leave a Comment

SEO Powered by Platinum SEO from Techblissonline