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_timeout, wait_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:
- The local machine from where you are trying to connect is not whitelisted on the server.
- The maximum number of connections for the user has been exceeded.
- 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?