简体   繁体   English

使用Self Provisioned测试装置运行负载测试时出现套接字异常

[英]Socket Exception while running load test with Self Provisioned test rig

I am getting the Socket Exception while running load test on self-provisioned test rig. 在自配置的测试平台上运行负载测试时,出现套接字异常。

I am trigger those load tests in agent machine(self-provisioned test rig) from my local machine. 我在本地计算机上触发了代理计算机(自配置的测试设备)中的那些负载测试。

Note : For first 2 to 3 minutes test iterations are passing , after that we are getting the Socket Exception. 注意:在开始的2到3分钟内,测试迭代通过了,此后我们得到了Socket Exception。

Below is the error message : 以下是错误消息:

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. 连接尝试失败是因为连接的一方在一段时间后未正确响应,或者建立的连接失败是因为连接的主机未能响应。

Below are the stack trace details : 以下是堆栈跟踪详细信息:

at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult) at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception) 在System.Net.ServicePoint.ConnectSocketInternal上的System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)(Boolean connectFailure,Socket s4,Socket s6,Socket&socket,IPAddress&address,ConnectSocketState状态,IAsyncResult asyncResult,Exception&Exception)

Run Time - 20min 片长-20分钟
Sample rate - 10sec 采样率-10秒
warm up duration 10sec 预热时间10秒
number of agents used - 2 使用的代理数量-2
Load pattern : 加载方式:
initial load - 10user 初始负载-10user
max user count - 300 最大用户数-300
step duration - 10sec 步长-10秒
step user count - 10 步骤使用者人数-10

Although, by Changing above values I am still getting the exception in the same way. 虽然,通过更改上述值,我仍然以相同的方式得到例外。

I am using Visual studio 2015 enterprise. 我正在使用Visual Studio 2015企业版。

The question states: start with 10 users, every 10 seconds add 10 users to a maximum of 300. Thus after 29 increments there will be 300 users and that will take 29*10 seconds which is 4m50s. 问题指出:从10个用户开始,每10秒增加10个用户,最多增加300个用户。因此,在增加29个之后,将有300个用户,这将花费29 * 10秒,即4m50s。 The test will thus (attempt to) run with the maximum load of 300 users for the remaining 15m10s. 因此,该测试将(尝试)在剩余的15个月中以300位用户的最大负载运行。

Given that all tests pass for the first 2 or 3 minutes plus the the error message, that suggests that you are overloading some part of the network. 假设所有测试在最初2或3分钟内通过测试,并显示错误消息,则表明您正在过载网络的某些部分。 It might be the agents, it might be the servers or it might be on the connections between them. 它可能是代理,也可能是服务器,或者可能在它们之间的连接上。 Some network components have a maximum number of active connections and the 300 users might be too many. 某些网络组件的活动连接数最大,而300个用户可能过多。

Increasing the load so rapidly means you do not clearly know what the limiting value. 如此迅速地增加负载意味着您​​不清楚不清楚极限值是多少。 The sampling rate (at 10 seconds) seems high. 采样率(10秒)似乎很高。 At each sampling interval a lot of data is transferred (ie the sample data) and that can swamp parts of the network. 在每个采样间隔,都会传输大量数据(即采样数据),并且可能淹没部分网络。 You should look at the network counters for the agents and controller, also the servers if available. 您应该查看代理和控制器的网络计数器,以及服务器(如果有)的网络计数器。

I recommend changing the load test steps to add 10 users every 30 seconds, so it takes about 15 minutes to reach 300 users. 我建议更改负载测试步骤,以每30秒添加10个用户,因此大约需要15分钟才能达到300个用户。 It may also be worth reducing the sample rate to every 20 seconds. 将采样率降低到每20秒也可能是值得的。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM