IBM Support

WebSphere Application Server HTTP plug-in has lingering close_wait connections

Troubleshooting


Problem

When the IBM® WebSphere® Application Server keeps alive time-out fires on a connection, the connection will go into a close_wait state on the Web server and fin_wait state on the Application Server.

Cause

This is proper RFC/TCP connection behavior since the fin_wait socket left on the Application Server will be closed out by the operating system's TCP timers. On the Web server side of the connection, the socket is still in the close_wait state which will not be cleaned up by the operating system, but the socket will be cleaned up by the Web server plug-in. The connection will be reset by the plug-in the next time the connection is used again or when the Web server process exits.

When the next client request comes into the plug-in and the request has been mapped to an application server, the plug-in will try to reuse any and all existing connections that go to that Application Server's port. If any of the known connections are found to be in an unusable state like close_wait, the connection(s) will be reset. When there are no further known connections to be used, the plug-in will establish a new connection to the Application Server port.

The Application Server HTTP plug-in does not actively monitor the TCP connection state between itself and the Application Server for performance reasons. When running in a production environment, there will be continuous client requests, and all of the plug-ins to Application Server connections will be reused. The number of close_waits left hanging around will be far lower.

When in a testing environment, you may easily have 1000 simultaneous client test requests come in and then nothing further; so these close_waits will not go away. These close_waits will be destroyed when the next client comes in that can reuse the connection to that Application Server port.

Resolving The Problem

Having lingering close-waits is normal based on Plug-in and WebSphere's communication scheme. There are no specific recommended values, but the following are areas you can review.

From a performance standpoint, the options to tune and minimize close_waits would be to increase the KeepAlive time-out on each Application Server to allow the Web server plug-in to reuse connections as often as possible.

Web servers that utilize many child processes, such as IBM HTTP Server V6, V6.1 ,V7 and V8, allow the Web server to terminate idle processes that will also terminate the idle connections to Application Server owned by those processes.

[{"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Plug-in","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF012","label":"IBM i"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"8.5.5;8.5;8.0;7.0","Edition":"Base;Express;Network Deployment","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSNVBF","label":"Runtimes for Java Technology"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Java SDK","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
15 June 2018

UID

swg21222632