Consultor Eletrônico



Kbase P136353: Application server agent hangs in receiving mode running a web services request
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   10/03/2009
Status: Unverified

SYMPTOM(s):

Application server agent hangs in receiving mode running a web services request

Java Stack trace taken from the wsa1.wsa.log

SEVERE: Endpoint null ignored exception: java.net.SocketException: Too many open files


Stack Trace:
java.net.SocketException: Too many open files
at java.net.ServerSocket.createImpl(ServerSocket.java:255)
at java.net.ServerSocket.getImpl(ServerSocket.java:205)
at java.net.ServerSocket.bind(ServerSocket.java:319)
at java.net.ServerSocket.<init>(ServerSocket.java:185)
at java.net.ServerSocket.<init>(ServerSocket.java:141)
at org.apache.tomcat.util.net.DefaultServerSocketFactory.createSocket

netstat -a shows a huge number of ports in close_wait status

FACT(s) (Environment):

Application have a large number of requests at same time
OpenEdge 10.1x
SuSe Linux
Tomcat
Sun JDK 1.4

CAUSE:

A bug in SUSE JDK does not allow the sockets to close appropriately. The bug is described in the URL:http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6215050

FIX:

1 - Make sure the JDK is the minimum version reported in the bug fix
2 - Change the GC parameter to allow running the garbage collector more often and clear the pending closed sockets. An example of how changing the GC behavior by changing the startup command line:
-XX:MaxPermSize=128m -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+UseTLAB -XX:+CMSIncrementalMode -XX:+CMSIncrementalPacing -XX:CMSIncrementalDutyCycleMin=0 -XX:CMSIncrementalDutyCycle=10 -XX:MaxTenuringThreshold=0 -XX:SurvivorRatio=256 -XX:CMSInitiatingOccupancyFraction=60 -XX:+DisableExplicitGC
3 - Increase the number of total opened files and total opened files by process in the OS kernel.