WCF服务自动停止工作。 [英] WCF Service stop working automatically.

查看:292
本文介绍了WCF服务自动停止工作。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有Windows服务,我们用它来托管 WCF 服务,但它会在我们的事件查看器中显示以下错误而自动停止工作。



 OnStart: 已经是IP端点上的侦听器 10  0  0  103  8000 。确保您没有尝试在应用程序中多次使用端点并且没有其他监听端点的应用程序。 

Disposed:无法使用 object ,System.ServiceModel.ServiceHost communication,因为 处于Faulted状态。





这些消息我们放入事件查看器 OnStart Disposed 事件Windows服务。



如果您有任何解决方案,请帮助我。

解决方案

您应该查看低于资源。他们可能会帮助你。



端口8000正在解决问题。



问题 - 1

1. WCF MexTCP问题 - IP端点上已有一个监听器0.0.0.0:portnumber [ ^ ]。



2. WCF - IP端点0.0.0.0:808上已有一个侦听器 [ ^ ]。

引用:

我猜你已经配置了一个IIS网站/应用程序来使用Net .Tcp - 808是他们使用的默认端口(在这种情况下阻塞)。



要么在IIS中禁用侦听器 - 要么使用不同的端口(net.tcp) :// localhost:909 / ...)



问题 - 2

Quote:

服务器将自动中止连接时没有接收到消息的连接,持续时间等于接收超时(默认为10分钟)。这是一个DoS缓解措施,可以防止客户端强制服务器无限期地打开连接。



因为服务器因为闲置而中断连接客户端获得此异常。



您可以通过在服务器上配置接收超时来控制服务器允许连接在中止之前空闲多长时间结合。


We have Windows Service which we are use for hosting the WCF Service but it stop working automatically by showing the following error in our event viewer.

OnStart : There is already a listener on IP endpoint 10.0.0.103:8000.  Make sure that you are not trying to use this endpoint multiple times in your application and that there are no other applications listening on this endpoint.

Disposed: The communication object, System.ServiceModel.ServiceHost, cannot be used for communication because it is in the Faulted state.



These message we put into event viewer OnStart and Disposed event of windows service.

Please help me if you have any solution.

解决方案

You should look into the below resources. they might help you.

The port 8000 is creating the problem.

Issue - 1
1. WCF MexTCP issue -There is already a listener on IP endpoint 0.0.0.0:portnumber[^].

2. WCF - There is already a listener on IP endpoint 0.0.0.0:808[^].

Quote:

I would guess that you have configure one of your IIS web sites/apps to use Net.Tcp - 808 is the default port they use (and block in this case).

Either disable the listener in IIS - or use a different port (net.tcp://localhost:909/...)


Issue - 2

Quote:

The server will automatically abort connections over which no message has been received for the duration equal to the receive timeout (default is 10 mins). This is a DoS mitigation to prevent clients from forcing the server to have connections open for an indefinite amount of time.

Since the server aborts the connection because it has gone idle, the client gets this exception.

You can control how long the server allows a connection to go idle before aborting it by configuring the receive timeout on the server''s binding.


这篇关于WCF服务自动停止工作。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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