Appendix B: TCP/IP Parameters

If 4000 sockets are rapidly opened and closed in less than four minutes, the default maximum setting for client anonymous ports is reached, and new socket connection attempts fail until the existing set of TIME_WAIT sockets times out.

Error 10048 occurs when all available ports are used on an injector machine.

To resolve this problem, use the RegistryEditor tool to add (or modify) the TcpTimedWaitDelay and MaxUserPort parameters in the registry.

(HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\Tcpip\Parameters) and reboot the computer:

TcpTimedWaitDelay: REG_DWORD: 30 (0x1E)
Valid Range 30-300 (decimal)
Default 240 decimal
Description This parameter determines the length of time that a connection will stay in the TIME_WAIT state when being closed. While a connection is in the TIME_WAIT state, the socket pair cannot be re-used.
MaxUserPort: REG_DWORD: 65534 (0xFFFE)
Default 5000 decimal
Maximum value 65534 decimal (0xfffe)
Description This parameter determines the maximum number of open ports


Another solution to clean connections that are in TIME_WAIT state is to modify the TestExecuterweb.ini file:

  1. Set the Linger option to 0: sockets will be immediately closed without staying in a TIME_WAIT state for the time specified by the "TcpTimedWaitDelay" value.
  2. Set ReuseAddr to 1: To inform the Windows Sockets provider that a bind on a socket should not be disallowed because the desired address is already in use by another socket.

See also:

Go back to the Learning center:

Copyright © AgileLoad. All rights reserved.
Agile Load testing tool| Contact AgileLoad | Terms of Use | Sitemap