远程登录到SQL Server 2008 R2 [英] Login to SQL Server 2008 R2 remotely
问题描述
Hello All
这似乎是互联网上的一个常见问题,所以让我详细介绍一下我的环境和我所做的步骤:
客户端 - 带有SQL Management Studio的Windows 7 32位
服务器 - 带有SQL Server 2008 R2的Windows Server 2008 R2 [默认未命名实例]和SQL管理工作室
对于服务器,我添加了应用程序服务器角色。我想我还添加了Web服务器角色。服务器和客户端在同一个局域网上。
安装并测试SQL服务器的Windows身份验证后,这是 - 简短的话 - 我做了什么来启用SQL服务器远程登录:
1 - 启用并启动所有SQL Server服务。
2 - 为SQL Server启用TCP / IP。 [我重新启动服务器以确保在此步骤之后]
3 - 在防火墙上启用TCP端口访问。
4 - 允许sqlservr.exe和sqlbrowser.exe在防火墙。
5 - 创建另一个用户而不是sa并赋予它sysadmin角色。
在客户端机器上,当我打开SQL管理工作室,我尝试使用端口[192.168.1.25,1443]登录服务器IP地址,服务器名称,服务器名称或IP。用户名和密码是正确的。
在前面的解释之后,我无法远程访问服务器的SQL Server,我得到了一个着名的错误网络相关或实例具体。请注意,出现相同的错误消息,但在执行上述步骤后会出现不同的错误代码。我无法提供错误代码,因为我现在不在机器上。任何帮助真的很感激!谢谢!
Hello All
It seems this is a common problem over the internet so let me give you details on my environment and the steps I did:
Client - Windows 7 32-bit with SQL Management Studio
Server - Windows Server 2008 R2 with SQL Server 2008 R2 [Default not named instance] and SQL Management Studio
For the server I added Application server role. I think I also added Web server role. The server and client are on the same LAN.
After installation and testing windows authentication to the SQL server, this is -in short words- what I did to enable SQL server remote login:
1 - Enabled and started all SQL Server services.
2 - Enabled TCP/IP for SQL Server. [I restarted the server to be sure after this step]
3 - Enabled TCP port access on the firewall.
4 - Allowed sqlservr.exe and sqlbrowser.exe on the firewall.
5 - Created another user rather than sa and give it sysadmin role.
On the client machine, when I open SQL management studio, I tried to login with server IP address, server name, server name or IP with port [192.168.1.25,1443]. Username and password are correct.
After the previous explanation, I can't access the server's SQL Server remotely, I get the famous error "A network-related or instance specific". Notice that the same error message appear, but with different error codes after performing some steps from the above. I can't provide you with the error codes since I'm not with the machine right now. Any help is really appreciated! Thanks!
推荐答案
你应该检查几件事
- 防火墙检查,如果你重新配置一个单独的防火墙也检查一下服务器计算机上的防火墙配置为允许连接
- 从SQL Server配置检查TCP / IP已启用且远程连接是如果需要,允许
- 检查目标是否为命名实例,并确保在连接中提供实例名称
该端口不应该是1433吗?
SQL Server的默认端口是1433.端口不需要是1433,但1433是SQL Server的官方Internet分配号码机构(IANA)套接字号。
http://support.microsoft.com/kb/ 287932 [ ^ ]
Shouldn't the port be 1433 ?
"
The default port for SQL Server is 1433. The port doesn't need to be 1433, but 1433 is the official Internet Assigned Number Authority (IANA) socket number for SQL Server.
"
http://support.microsoft.com/kb/287932[^]
这篇关于远程登录到SQL Server 2008 R2的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!