You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by JacobS <ja...@gmail.com> on 2011/09/07 10:22:19 UTC

Too many open files using ActiveMQ 5.4.1

I have an AcitiveMQ broker 5.4.1 running on Ubuntu server with 700 clients
connected via openwire and less then a minute after starting the server I am
receiving many exceptions:

2011-09-07 11:15:24,911 ERROR TransportConnector:234 - Could not accept
connection : java.net.SocketException: Too many open files [{ActiveMQ
Transport Server:
tcp://0.0.0.0:61616?wireFormat.tightEncodingEnabled=false?jms.prefetchPolicy.all=50}]
2011-09-07 11:15:24,911 DEBUG TransportConnector:236 - Reason:
java.net.SocketException: Too many open files [{ActiveMQ Transport Server:
tcp://0.0.0.0:61616?wireFormat.tightEncodingEnabled=false?jms.prefetchPolicy.all=50}]
java.net.SocketException: Too many open files
        at java.net.PlainSocketImpl.socketAccept(Native Method)
        at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:390)
        at java.net.ServerSocket.implAccept(ServerSocket.java:453)
        at java.net.ServerSocket.accept(ServerSocket.java:421)
        at
org.apache.activemq.transport.tcp.TcpTransportServer.run(TcpTransportServer.java:279)
        at java.lang.Thread.run(Thread.java:662)

This problem reproduces easily ( every restart ).

Any idea why this is happening or how can I find the source of the problem ?


--
View this message in context: http://activemq.2283324.n4.nabble.com/Too-many-open-files-using-ActiveMQ-5-4-1-tp3795543p3795543.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Too many open files using ActiveMQ 5.4.1

Posted by JacobS <ja...@gmail.com>.
Thanks, I think changing the open files limit solved the problem.

--
View this message in context: http://activemq.2283324.n4.nabble.com/Too-many-open-files-using-ActiveMQ-5-4-1-tp3795543p3795833.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Too many open files using ActiveMQ 5.4.1

Posted by Torsten Mielke <to...@fusesource.com>.
You operating system limits the number of file descriptors that one process may open. 
Run ulimit -a on your shell and inspect the value for "open files". Using ulimit -n you can change that limit to a higher value.
Perhaps use 2048 or higher then retry your ActiveMQ application.


Torsten Mielke
torsten@fusesource.com
tmielke@blogspot.com