distal-attribute
distal-attribute
distal-attribute
distal-attribute

keep getting error #0

User, date Message
Written by ploppy
2 years ago
Category: Creating a connection
2 posts since Sun, 02 Sep 12
hello
as a new user to heidi, i am trying to work out why i cannot create connection between my pc and server. I have entered all the correct credentials from pc but what I did notice was on the server it is currently setup for localhost and also there is no port # allocated. how do in check wahat i need to be setup on server machine to create connection? Many thanks

I am using centos6 with control panel.

PS: also I cannot seem to attach a pic here to show problem.
Written by ansgar
2 years ago
4940 posts since Fri, 07 Apr 06
You could post the text of the error message. Did you know that, in any Windows error popup dialog, you can press Ctrl+C to get the message into your clipboard.
Written by ploppy
2 years ago
2 posts since Sun, 02 Sep 12
good idea. here is the error: [Window Title]
Error

[Content]
SQL Error (2003) in statement #0: Can't connect to MySQL server on 'xx.xxx.xxx.xx' (10061)

[OK]
Written by ansgar
2 years ago
4940 posts since Fri, 07 Apr 06
Ok, I guess you entered the right IP or hostname. You said

ploppy wrote: on the server it is currently setup for localhost


That may be the cause. You must check that on server shell, by examining your mysql.cnf/ini file. Find the setting for "skip-networking".
Or, if that's not set at all or is set to "0", then start a command line shell on MySQL and fire a

SELECT Host, User FROM mysql.users WHERE User='yourusername'


Then, if the "Host" column shows some specific IP address, localhost or whatever, that's the cause why you cannot connect from other remote computers.
Written by logg
6 months ago
1 posts since Tue, 21 Jan 14
Since this is the top google result for
"
[Window Title]
Error

[Content]
SQL Error (2003) in statement #0: Can't connect to MySQL server on 'localhost' (10061)"

, I will leave my resolution here:

Try increasing the plink.exe timeout under the SSH tunnel tab of the Heidi SQL session manager window. At the default 4 seconds, I received this error. After increasing the timeout to 8 seconds, I was able to connect.
Written by AlexPreslandMoney, Euro
4 months ago
4 posts since Sun, 30 Mar 14
I found a problem of caching the server's host key... HeidiSQL doesn't spot this and prompt the user to accept it into PuTTY/Plink's local cache on the first connection.

There are two solutions:
[1] Manually establish the SSH connection using PuTTY first, in order to get the key into the local cache
or
[2] Follow the instructions on http://caseymclaughlin.com/articles/ssh-tunnels-with-plink-and-heidisql to use plink to get the server key in the cache.
Written by AlexPreslandMoney, Euro
4 months ago
4 posts since Sun, 30 Mar 14
...this only applies if you're using the "MySQL (SSH tunnel)" network type option.
Written by ansgar
4 months ago
4940 posts since Fri, 07 Apr 06
I rewrote the whole plink logic and committed that yesterday. That way, HeidiSQL prompts you whether to cache the host key, and other error messages are displayed as well. You should update to the latest build and try again.
Written by AlexPreslandMoney, Euro
4 months ago
4 posts since Sun, 30 Mar 14
Cool. I'll try to find some time to go and clear out my server key cache and do some additional validation for you.
Written by jfalchMoney, Euro
4 months ago
382 posts since Sat, 17 Oct 09
works well here (after removing stored session key from registry).

small nitpick: please remove the final (y/n) in text, since it is immediately followed by Yes/No buttons..

good solution to a long-time problem.
Written by AlexPreslandMoney, Euro
4 months ago
4 posts since Sun, 30 Mar 14
Yup, all working just fine. I also corrupted one of my keys and was correctly warned that it had changed.

I agree with jfalch's nit pick.

Great work.
Written by ansgar
4 months ago
4940 posts since Fri, 07 Apr 06
"(y/n,...)" removed in r4749.
Written by jfalchMoney, Euro
4 months ago
382 posts since Sat, 17 Oct 09
thanks.
 

Please login to leave a reply, or register at first.