728x90


I have developed an application in VB6, and am using an online MySQL database server for storing my application's data.

The first time I try to connect to my database server is successful, but after closing my application and starting it again I get:

Can't connect to MySQL server(10060)"

After some time (approximately 30 minutes), I can successfully connect to the database again.

  • I have given maximum values to all of MySQL system and global variables like connection_timeoutwait_timeout etc.
  • I have granted all permissions to my MySQL user.
  • The firewall on my computer is turned off.
  • All connections are properly closed when the application closes.

I have asked the technical people who provide the Online MySQL Database service and they gave me these three reasons:

  1. The local machine from where you are trying to connect is not whitelisted on the server.
  2. The maximum number of connections for the user has been exceeded.
  3. The MySQL server was down at the time (though they said that their server was not down).

How can I solve the first two reasons, or determine that they are the cause of the problem? Or could there be another problem not listed there?

you need to make sure there is:

1) user created that has remote access for example user@'x.x.x.x'

2) there is a connection from the two machine ( they can ping each other for example or access each another by another method) the port is opened between the two machine

3) in my.ini/my.cnf there is blocking connection parameter like:bind-address=a.a.a.a or skip-networking

4) the service is up and running when you try to connect from the other machine


+ Recent posts