Bug 56320 - DefaultServlet leaks file handles
Summary: DefaultServlet leaks file handles
Alias: None
Product: Tomcat 8
Classification: Unclassified
Component: Connectors (show other bugs)
Version: 8.0.x-trunk
Hardware: PC Linux
: P2 regression (vote)
Target Milestone: ----
Assignee: Tomcat Developers Mailing List
Depends on:
Reported: 2014-03-27 08:44 UTC by jfclere
Modified: 2014-03-27 16:59 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description jfclere 2014-03-27 08:44:50 UTC
While running ab test against tomcat 8 I have the following failure:
44714 27-Mar-2014 04:41:00.605 SEVERE [http-bio-8001-Acceptor-0] org.apache.tomcat.util.net.JIoEndpoint$Acceptor.run Socket accept failed
244715  java.net.SocketException: Too many open files
244716         at java.net.PlainSocketImpl.socketAccept(Native Method)
244717         at java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java:398)
244718         at java.net.ServerSocket.implAccept(ServerSocket.java:530)
That doesn't depend on the connector.

And lsof says:
[hudson@messaging-09 tc8]$ lsof | grep ROOT | wc -l
[hudson@messaging-09 tc8]$ lsof | grep ROOT | grep 64KiB.bin | wc -l

64KiB.bin is the file I am requesting in ab.
Comment 1 jfclere 2014-03-27 09:18:18 UTC
In fact it seems it is linked with sendfile.
Comment 2 Mark Thomas 2014-03-27 16:59:58 UTC
Thanks for the report. I've fixed this in trunk and it will be included in 8.0.6 onwards.