#2003 - Can't connect to MySQL server on 'localhost' (10061)

awariss

Guppy
hi,
i am new to this forum..

i am getting the following error...

Welcome to phpMyAdmin 2.5.7-pl1


phpMyAdmin tried to connect to the MySQL server, and the server rejected the connection. You should check the host, username and password in config.inc.php and make sure that they correspond to the information given by the administrator of the MySQL server.

Error

MySQL said:


#2003 - Can't connect to MySQL server on 'localhost' (10061)


i installed :

Apache 2 Windows Binary (MSI installer)
PHP5 The PHP zip is under "Windows Binaries".
MySQL Windows x86.
PHPmyAdmin

for PHPmyAdmin what i did was......

Extract the zip file to .... /apache group/apache2/htdocs
The PHPmyAdmin dir has a long name so renamed it as "pma"
Then go to pma/config.inc.php

type:

$cfg['PmaAbsoluteUri'] = 'http://localhost/pma/';

but still it gives the error when i open http://localhost/pma/phpinfo.php


Mysql and Apache are running and still it gives the error.. can someone please help me out here...
 
Stephen

thanks for the reply..

do you mean that i should uninstall the current Apache, PHP, Mysql, and PHPmyAdmin and install the package you recommended.

is there any other way that i can configure phpmyadmin with its config file for the password, or configure it to have a form based login.

i went through a tutorial and it says that:
You may or may not configure the root user (remember this is your test bed not a production server)
if you decide not to set a root user then do not use a password in your connection functions.

i am really confused.. please help me!
 
I would recommend uninstalling and installing from that package, but you can attempt to work with it as you have now if you want. And as long as it is just on your local machine you can use the root password.
 
hi,

i am getting this error now when i start phpmyadmin. please help me with this..!! any idea of whats going on!

Server localhost
Error

MySQL said:


#2013 - Lost connection to MySQL server during query
 
Check your task manager, processes section, see if MySQL is still running or if it crashes when you execute the query.
 
stephen,

yeah! it does crash ... it just stays on only for a few seconds !

i really need some quick help...!
 
I would check the event viewer for any logs of the crash, and also see if there is logs file in the MySQL folder.
 
thanks for the quick reply !

sorry , but i couldn't find any log file in the MySQL folder..
i am really new to MySQL.. and really desperate to start working on it.

thanks in advance.
 
I don't know if there is much else I can do, remote like this.

MySQL should not be crashing for sure, in the event viewer(inside control panel, admin tools) see if any logs are there.
 
thanks for the reply !

yeah ! there are many logs in the event viewer.

the following is one of it.

wuaueng.dll (2056) SUS20ClientDataStore: The database engine stopped the instance (0).
 
That is a windows database, you will need to look for one that mentioned MySQL specifically.
 
I also have a similar problem. I see this message:

Can't connect to MySQL server on 'localhost' (10061)

and whenever I try to opne winmysqladmin.exe, the stoplight always goes to RED.. even if I choose to 'Start this service" it will still return to read...

please.. help... :(
 
I have exactly the same problem... Am trying to setup mysql so that I can use MY .NET application to run an MySQL database. Unfortunately I get the "Can't connect to MySQL server on 'localhost' (10061)" error...

I know this is a stupid question but, do I need IIS windows component to run MySQL?
 
I also discovered that my por 3306 is being blocked... which also happens to be the port that MySQL requires. How can I unblock this port?

I am using Windows XP Professional with SP2
 
It depends on what firewall you are using, if windows firewall, it will be in the windows firewall settings, if another, in their settings.
 
I tryed it with SP2 Firewall off and it was the same problem.

Anyway I walked around the problem by installing MySQL 4.0.25 isntead of 4.1. It did not worked when I first launched it either but I went to the WinSQLAdmin and selected "Stop the service". I reboot the computer and I got a permenent green light next time windows appeared... And now it's working nicely...
 
Oh, you need php5 for mysql4.1, as they are not compatible with each other(php4 and mysql4.1), they are compiled using different libraries.
 
Thanks Stephen I uninstalled and reinstalled the xampp: and it worked perfectly :D...as a newbie I thought I would be in for a long night brcause it was working untill I did the windows update! I also had to make sure my intranet settings were turned on
 
Back
Top