【发布时间】:2012-12-05 15:16:35
【问题描述】:
我的几个网站突然出现此错误,我不确定是什么问题。 这些网站已经运行 2 年多了,这是我第一次看到这个错误。
"连接尝试失败,因为连接方在一段时间后没有正确响应,或者建立连接失败,因为连接的主机没有响应 XX.XX.XXX.XXX:80"
堆栈跟踪如下。
[SocketException (0x274c): A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond XX.XX.XXX.XXX:80]
System.Net.Sockets.Socket.DoConnect(EndPoint endPointSnapshot, SocketAddress socketAddress) +239
System.Net.Sockets.Socket.InternalConnect(EndPoint remoteEP) +35
System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Int32 timeout, Exception& exception) +224
[WebException: Unable to connect to the remote server]
System.Net.HttpWebRequest.GetRequestStream(TransportContext& context) +1867457
System.Net.HttpWebRequest.GetRequestStream() +13
Controls_IpConfigInner.stripConfig(String strClientIp) +136
Controls_IpConfigInner.Page_Load(Object sender, EventArgs e) +86
System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14
System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35
System.Web.UI.Control.OnLoad(EventArgs e) +99
System.Web.UI.Control.LoadRecursive() +50
System.Web.UI.Control.LoadRecursive() +141
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627
跟踪告诉我它与套接字有关,但没有套接字编程。
【问题讨论】:
-
你检查过防火墙吗?也许它是开启的,而你已将其禁用
-
防火墙已打开,但我确实在服务器上运行了其他 wesbites。他们能够连接到数据库。
标签: c# asp.net networking connection database-connection