发生传输级错误 [英] A transport-level error has occurred

查看:265
本文介绍了发生传输级错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


  

可能重复:结果
  <一href=\"http://stackoverflow.com/questions/2962927/a-transport-level-error-has-occurred-when-receiving-results-from-the-server\">A已经发生传输级错误接收从服务器的结果时



  

发生传输级错误
  将请求发送到所述时
  服务器。 (供应商:共享内存
  提供程序,error:0 - 无过程是在
  该管的另一端。)


我们越来越我们的服务器上间歇性地出现以下错误消息。我们正在运行与SQL Server 2008数据库中的asp.net 4 web应用程序。有没有人遇到此错误信息,并解决阻止这种情况发生。

奇怪的是这个问题没有出现我们开发的系统上,我们发现它进行复制,由于这个问题的性质零星非常困难的。

至今还没有找到一个解决这个问题。


解决方案

随着错误消息表示,有一个在SQL Server中的previously打开的会话连接问题。

尝试:

  SqlConnection.ClearAllPools();


<一个href=\"http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqlconnection.clearallpools.aspx\">SqlConnection.ClearAllPools方法重置(或清空)连接池。如果有在通话时使用的连接,它们被适当地标记,并将被丢弃(而不是被返回到池中)时关闭上调用它们。

Possible Duplicate:
A transport-level error has occurred when receiving results from the server

A transport-level error has occurred when sending the request to the server. (provider: Shared Memory Provider, error: 0 - No process is on the other end of the pipe.)

We are getting the following error message appearing intermittently on our server. We are running a asp.net 4 web application with SQL Server 2008 database. Has anyone ever come across this error message and a solution to stop this happening.

The strange thing is this issue was not occurring on our dev system and we are finding it very difficult to replicate due to the sporadic nature of this issue.

Still have not found a solution to this issue.

解决方案

As the error message indicates, there is a connectivity problem with a previously opened session in SQL Server.

Try:

SqlConnection.ClearAllPools();


SqlConnection.ClearAllPools Method resets (or empties) the connection pool. If there are connections in use at the time of the call, they are marked appropriately and will be discarded (instead of being returned to the pool) when Close is called on them.

这篇关于发生传输级错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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