Unable to bind to ports on a Linux operating system after restarting the server
Important: Applicable to WebSphere®
Application Server traditional
You might experience a long wait period for the Linux operating systems to release the TCP
ports after you restart a WebSphere Application
Server, in any of the following scenarios.- Start the server immediately after you stop the Java™ process
- Restart the server
- Restart the server in debug mode
The following message might appear in the SystemOut.log file
when the startServer command is issued immediately
after you stop the server process.
[6/26/11 4:41:59:647 EDT] 00000018 TCPPort E TCPC0003E: TCP
Channel TCP_2 initialization failed. The socket bind failed for localhost and port 9083. The port may already be in use.
After
the port is released by the operating system, WebSphere Application Server can bind to
the port. You might see the following message after a few minutes:
[6/26/11 4:44:04:677 EDT] 00000018 TCPChannel A TCPC0001I: TCP Channel TCP_2 is listening on localhost port 9083.
There
is no solution for this limitation. However, you can try to tune
up the timeout value by logging in to the Linux operating system as a root user.
After you are logged in, add the following entry in sysctl.conf file,
typically available in the etc directory. net.ipv4.tcp_fin_timeout = 30
Adding a timeout entry in sysctl.conf file
does not resolve the problem. However, the operating system is scheduled
to clean up the ports within the specified time duration. In this
case, the cleanup happens in 30 seconds.