很慢连接到SQL Server 2005只有当使用ADO.NET的SqlClient [英] Very slow connection to SQL Server 2005 only if using ADO.NET with SqlClient

查看:107
本文介绍了很慢连接到SQL Server 2005只有当使用ADO.NET的SqlClient的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个全新的服务器与Windows 2008 Server的64位+ SQL Server 2005标准版SP3。

I have a brand new server with Windows 2008 Server 64 bit + SQL Server 2005 Standard Edition SP3.

当我尝试打开该服务器从客户端在同一个域(Windows XP中,NET 3.5的)的连接,它需要大约20秒,打开连接。

When I try to open a connection to this server from a client in the same domain (Windows XP, .Net 3.5), it takes around 20 seconds to open the connection.

打开连接后,一切都快速和往常一样。

After opening the connection, everything is fast as usual.

在使用MDAC 2.8连接或ADO.NET OLEDB中,是没有问题的。

When using a MDAC 2.8 connection, or ADO.NET OleDb, there is no problem at all.

我怎么能找到的连接速度慢的原因是什么?

How can I find the reason for the slow connection?

推荐答案

问题是在服务器上运行防火墙。我增加了一个例外,1433端口,问题就消失了。

The problem was the firewall running on the server. I added an exception for port 1433 and the problem was gone.

可能的解释:也许使用OLEDB当连接尝试命名管道第一,绕过防火墙规则

Possible explanation: maybe when using OLEDB the connection tries Name Pipes first, bypassing the firewall rules.

这篇关于很慢连接到SQL Server 2005只有当使用ADO.NET的SqlClient的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆