Apache tomcat java.net.socketexception too many open files




















It seems that Tomcat was having a multitude of opened connections to one of the web services used by the application. So it looks like the connections between my website and the web service were never closed! In conclusion, if you get the same exception, try to find where the problem is coming from before increasing the maximum number of open file descriptors.

Java , java. SocketException , lsof , open file descriptors , Tomcat , Too many open files , ulimit. This entry was posted on 20 Dec , and is filed under Java. You can follow any responses to this entry through RSS 2.

You can skip to the end and leave a response. Pinging is currently not allowed. Home About Contact Us. We keep running out of open files whenever after just hrs since the JBoss server is started. We also increased the ulimit max open files number ffrom to but still we seem to be maxing out this number after a few hrs or when doing load testing. JBoss 4. The following are the errors in the server. JIoEndpoint] Socket accept failed java. SocketException: Too many open files at java. There are 2 things that i have done to overcome this problem right now.

But there is a new problem which has cropped up now. Cheers Kiran. You should not set it that high, that might be reason your CPU is spiking when you do the load test, it will keep creating new threads for your incoming request. Even if you are expecting concurrent request, i think 50 threads should be able to handle that. Also you can use acceptCount which is a queue for all your incoming connection requests when all possible request processing threads are in use.

I was able to resolve the problem. Navigate to "jboss Sorry for asking this Naming] Naming accept handler stopping java. Share your code! Is the tomcat running on a Windows or on a Linux machine?

Show 2 more comments. Active Oldest Votes. To increase it, follow the instructions below Too many open files Tomcat.

Improve this answer. DRCB 2, 13 13 silver badges 21 21 bronze badges. Zouzias Zouzias 2, 1 1 gold badge 20 20 silver badges 31 31 bronze badges.

I have already check and increase the number of open files to unreachable number. I think it is more a bad managament of the threads inside the application, could it be? Is there a way to see a list of those open files? And would be useful to see what thread had opened them. Add a comment. This will display all open files of that process.

Tooraj Jam 1, 14 14 silver badges 27 27 bronze badges. Format it well. Yes value reload needs log back — Pramod S. Jacek Cz Jacek Cz 1, 1 1 gold badge 14 14 silver badges 22 22 bronze badges.

Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown.



0コメント

  • 1000 / 1000