Welcome: Guest
NOTE: This site is no longer maintained. Upgrade to the latest version of ipMonitor ยป

Knowledge Center > FAQs
Why Does the "NETSTAT -A" Command List so many ipMonitor TCP/IP Connections?
Symptom

Running a "NETSTAT -A" command from the command prompt shows a large number of TCP/IP connections established by the ipMonitor software. This increased network traffic can affect ipMonitor's ability to create new connections, especially since many existing TCP/IP connections remain in a TIME_WAIT (reserved) state. Ultimately, if ipMonitor is unable to open new connections, Monitor failures can occur.

Cause

The majority of TCP/IP connections displayed are Ephemeral (temporary) Ports that have in fact been closed. Although neither the Operating System nor ipMonitor are currently using these connections, Ephemeral Ports remain "reserved" for a period of time before they can be reused. This "reserved" state is denoted by a TIME_WAIT label.

Microsoft limits the number of connections to 3,975 by default, meaning that there can only be 3,975 TCP/IP connections open at any given time. In addition, the TIME_WAIT state is configured by default to be 240 seconds. This means that Windows can only support an average of 33 TCP/IP connections per second. ipMonitor must then wait 240 seconds before being able to reuse those connections. If you have a large number of configured Monitors set to retest resources at short intervals, 3,975 connections every 4 minutes may simply not be enough.

Resolution

If you encounter this issue, we suggest attempting the following troubleshooting steps, in the order they're listed:

  1. Increase the refresh time between Monitor tests
  2. Modify the relevant Windows registry key to allow for a greater number of simultaneous connections
  3. Modify the relevant Windows registry key to adjust the duration of the TIME_WAIT state

Important! Troubleshooting steps 2 and 3 require making changes to the Windows® registry, which can result in severe system damage if performed incorrectly. Before you modify the registry, make a backup copy and ensure you understand how to restore the registry if a problem occurs. For information regarding backing up, restoring, and editing the registry, refer to the Description of the Microsoft Windows Registry article available within Microsoft's Knowledge Base.

1. Increase the Refresh Time between Monitor Tests

If possible, we suggest configuring your Monitors to use the default value of 300 seconds between Monitor tests. This optimal setting ensures there are enough TCP connections available when needed.

2. Allow for a Greater Number of Simultaneous Connections

Increasing the maximum number of available Ephemeral Ports allows for a greater number of simultaneous TCP connections:

  1. Start the Registry Editor (Regedt32.exe)
  2. Access the following registry key:
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters
  3. Add a DWORD value to this registry key:
    Name: MaxUserPort
    Type: DWORD
    Value: 65534 (decimal)
  4. Exit the Registry Editor.

3. Adjust the Time it takes for a TCP Port to be Released

Reducing the value of the TIME_WAIT state results in TCP connections being reused faster, therefore allowing for an increased number of connections during the same length of time. Please note that if the value is too low, the TCP connection may be closed before Monitor testing is complete.

  1. Start the Registry Editor (Regedt32.exe)
  2. Access the following registry key:
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters
  3. Add a DWORD value to this registry key:
    Name: TCPTimedWaitDelay
    Type: REG_DWORD - Time in seconds
    Value: 120 (decimal)
  4. Exit the Registry Editor.
Additional Resources

If you're still having difficulties after consulting this document, contact ipMonitor's Technical Support department by phone at 819.772.4134, or by email at support@ipmonitor.com. The Support department is open between the hours of 9am and 5pm Eastern Time, Monday through Friday.

For information on other features and concepts related to those discussed in this article, refer to the following ipMonitor resources:

< Back

Last Updated: April 24, 2006 | What did you think of this topic?

Privacy Statement | Terms of Use | EULA | Contact | Site Map

Prices displayed do not reflect international pricing unless otherwise stated. Please see our international price list for current pricing specific to your location. All prices are subject to change without notice.

© 2003-2008 SolarWinds.net, Inc. All Rights Reserved. SolarWinds®, the SolarWinds logo, ipMonitor®, LANsurveyor®, and Orion® are among the trademarks or registered trademarks of the company in the United States and/or other countries. All other trademarks are property of their respective owners.