Get the App
SLTechnology News&Howtos  ›  Internet Technology  › 

Summary of errors in jmeter pressure measurement and prediction:

Shulou Source: shulou.com Published: 2022-06-03 07:29:19 11月23日 Update

1. Single scene pressure test: 1500 users continue to be concurrent for 3 minutes, jmeter script error:

Response code: Non HTTP response code: java.net.BindException

Response message: Non HTTP response message: Address already in use: connect

Cause analysis:

Windows ports are exhausted (default 1024-5000), and it takes 2-4 minutes for the operating system to release these windows again, so you can increase the available ports of windows to solve this problem. The maximum number of windows ports is 65534

Solution 1:

Modify the operating system registry

1. cmd Input: regedit

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\TCPIP\Parameters

3. New DWORD value, name: MaxUserPort, value: 65534 (decimal)

4. Restart the system

Solution 2:

Change HTTP request: to short link (remove check mark for keepAlive)

When both workarounds are set, the error percentage of requests can be significantly reduced

Second, socket closed

Cause of the problem: Under JMeter, when sending http requests, generally use keepAlive is selected by default. This is the connection protocol. This is checked by default (if it is not checked, it will not be saved), but the time setting in its configuration JMeter.properties is logged out by default. That is to say, it will not wait. Once the connection is idle, it will be disconnected immediately, resulting in a transaction failure in our pressure test.

Solution: modify httpclient4.idletimeout= set to a reasonable time, generally set to 10-60s (indicating that the connection will be disconnected after 10s), note that the unit here is ms. After the modification is completed, press the test again, and the error no longer exists.

Tags: Method port system operating system reason time idle error problem maximum transaction again decimal unit cause analysis scenario situation registry user percentage Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MySQL Xiaomi Shulou Tech Info OPPO Reno Linux