ADBlock errore

Program causes run-time error when run on specific machine



I have a VB app that was running fine on the LAN. The server was Windows 2003. I only moved the whole program to one of the PCs (XP + WAMP server). The program runs good on the local machine but when run from another workstation, I get the following error:

vb runtime error -2147467259 (80004005) [mysql][odbc 5.1 driver] could not connect to mysql server on x.x.x.x (10060)

x.x.x.x is the IP of the PC used as the server.

I see that a similar message is already posted on this forum but none of those are related to my problem as my program works locally. The VB6 program uses the same connection info.

The DB user has been set to allow requests from any host.

What could be the issue?



The error says cannot connect. This is a networking or firewall issue, not a permissions problem.

  1. See if you can successfully ping the server.
  2. See if anything else can connect to the server
  3. See if any other mysql client can connect.
  4. If this is the first ever mysql client to attempt connecting, check the server's logs for clues.

First, many thanks to wallyk and Marc B for leading me in the direction of checking for ports...

Here's the answer:

Actually the original my.ini had the correct settings. But I did these two things:

  1. In the section mysqld, I added the line enable-named-pipe.
  2. In the Windows XP firewall settings, I added port 3306 as an exception. This was the main culprit causing me 3 days of trouble :)

Then restart WAMP server and we're done.

I found this link from Microsoft, which gave me the thought of doing this final step.

Thanks again for all those inputs!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow