诊断与SQL Server的连接 [英] Diagnosing Connection to SQL Server
问题描述
我试图创建一个ODBC连接到SQL Server,但是当我这样做,我得到错误:
I'm trying to create an ODBC connection to SQL Server, but when i do, i get error:
Connection failed:
SQLState: '01000'
SQL Server Error: 10060
[Microsoft][ODBC_SQL Server Driver][TCP/IP Sockets] COnnectionOpen (Connect()).
Connection failed:
SQLState: '08001'
SQL Server Error: 17
[Microsoft][ODBC_SQL Server Driver][TCP/IP Sockets] SQL Server does not exist or access denied.
这是我试过的:
- 不是防火墙问题:尝试在SQL Server上的防火墙关闭,客户端关闭。也可以从客户端telnet 1433和工作正常。
- 不是一个访问问题:我可以从许多不同的计算机,包括SQL Server本身使用我在客户端上使用的帐户(使用SQL Server身份验证)
- 我可以ping主机名和IP地址。 (我试过两个)
我唯一能想到的是客户端计算机是windows server 2003,角色设置:
The only thing i can think of is that the client computer is windows server 2003, and has various roles setup:
- 文件服务器
- 应用服务器
- 终端服务器
- 域控制器
- DNS服务器
- File Server
- Application Server
- Terminal Server
- Domain Controller
- DNS Server
我不知道为什么这些服务设置,但暂时我不能关闭他们。它是任何这些,如果是,有一个方法来禁用它们的任何方面,可能是阻止SQL。
I don't know why these services are setup, but for the time being i can't shut them off. Would it be any of these, and if so, is there a way to disable any of the aspects of them, that might be blocking SQL.
任何建议真的赞赏!
推荐答案
找到问题。由于某些原因,即使SQL未在客户端上使用,它已安装,并通过转到所有程序 - > Microsoft SQL Server - >客户端网络实用程序,我发现原型TCP / IP使用端口4717.I不知道为什么该端口正在使用,甚至更进一步,我不知道为什么它甚至重要 - 我只是设置一个odbc连接,而不是使用sql server(在客户端)。无论哪种方式,我改变这是典型的端口(1433),像繁荣,ODBC连接工作像charm!
Found the issue. For some reason, even though SQL was not in use on the client, it was installed, and by going to All Programs -> Microsoft SQL Server -> Client Network Utility, i found that the protocal TCP/IP was using port 4717. I have no idea why that port was in use, and even further, i'm not sure why it would even matter - I was just setting up an odbc connection, and not using sql server (on the client) at all. Either way, I changed this to the typical port (1433), and like boom, ODBC connection works like charm!
这篇关于诊断与SQL Server的连接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!