Apache ActiveMQ – How to resolve java.io.IOException: Too many open files exception?
The Integration Zone is brought to you in partnership with Red Hat. Download the IDC Report: The Business Value of Red Hat Integration Products to learn more about Red hat Integration.
I have worked on ActiveMQ for quite a while, and there’s one annoying exception that I see all the time – java.io.IOException: Too many open files – which we see time to time.
[localhost:61613] ERROR TransportConnector – Could not accept connection : Too many open files
[email@example.com:8161] WARN log – EXCEPTION
java.io.IOException: Too many open files
at sun.nio.ch.ServerSocketChannelImpl.accept0(Native Method)
Have spent some time gooling about this error and got a rough idea on what this error is all about, what we can do to identify the issue, and (possibly!) fix it
I’ll need some more time to write what I’m doing to solve it, and btw, you can find the links that were helpful to me:
1. ActiveMQ 5.1.0 runs out of file descriptors with lots of ‘CLOSE_WAIT’ sockets: https://issues.apache.org/jira/browse/AMQ-1739
2. ActiveMQ forum:http://activemq.2283324.n4.nabble.com/too-many-open-files-td2364996.html