Groups | Blog | Home
all groups > sql server connect > september 2005 >

sql server connect : [DBNETLIB][ConnectionOpen (Connect()).]Specified SQL server not found.


SiJP
9/13/2005 4:44:36 AM
I am trying to connect to a SQL server that is on a remote network,
using Enterprise Manager. However, I am getting server not found
errors.

Here is my setup:
My PC, connects to the internet via a PDC, which has a cisco router
attached.

Web Server has SQL installed on it, I have TCP/IP configured, and the
logs are reporting that my server is listening on x.x.x.x:1433 which is
good. This server is not on the same network as my PC.

I beleive that my SQL server is correctly configured for IP based
connections. To test the connection, I ran this asp script from my PC
(local IIS).

<%
dim cst
dim cn
cst = "Provider=SQLOLEDB;" & _
"Data Source=<x.x.x.x>,<1433>;" & _
"Initial Catalog=myDB;" & _
"Network=DBMSSOCN;" & _
"User Id=user;" & _
"Password=pass"

set conn = CreateObject("ADODB.Connection")
conn.open cst
response.write "Connection Established"
conn.close
%>

I'm wondering why I am unable to connect to the server (apart from the
obvious username/passwords!! I thank you...). Possible points of
failure which I am checking:

- Router on my internet connection is restricting this port?
- Firewall on web server is blocking this port?

What other checks should I be making?

Thanks,
Si
Jens
9/13/2005 5:32:22 AM
Did you try using a hardcoded conenction string (just to take care of
any mistypings) like this one from
www.connectionstrings.com: Driver={SQL
Server};Server=Aron1;Database=pubs;Uid=sa;Pwd=asdasd;"

HTH, Jens Suessmeyer.
SiJP
9/13/2005 6:11:03 AM
I've tried using the SQL server registration wizard in Enterprise
Manager, as well as the hardcoded sample above. The connection string
is corrrect.

Thanks
Jens
9/13/2005 6:57:46 AM
Next thing would be (for me) to use a port sniffer, and sniff the port
(1433) for the SQL Server to see wheter it is reachable, if the Server
offers other services as http you could see if the sniff will a) get
through the firewall (with a ping) b) offers the SQL Server Service
though the firewall c) offers any Service 8through the firewall). The
prefered one for me is SuperScan.

HTH, Jens Suessmeyer.
SiJP
9/14/2005 1:19:49 AM
Thanks for the suggestion of using SuperScan... it's a great tool to
play with!

This is getting to be more of a network post, but you may have some
answers...

- I can connect to the servers web page through mozilla, by typing the
http address.
- Pinging the server's IP will timeout
- Doing a traceroute is weird.. the first hop is go to my proxy server
(which has the router) then nothing... even trying to trace
www.google.com isn't happening, however the DNS lookup works.
- SuperScan reports (when running a full scan) that 0 TCP and 0 UDP
ports are open..

I have little knowledge of networks, but it appears that my router is
not letting much go out. Would I be thinking along the right tracks?

Cheers
AddThis Social Bookmark Button