JIRA can't obtain connection from database due to no buffer space available
Symptoms
The following appears in the atlassian-jira.log
:
java.lang.RuntimeException: Unable to obtain a connection from the underlying connection pool
at org.ofbiz.core.entity.jdbc.interceptors.connection.ConnectionTracker.trackConnection(ConnectionTracker.java:59)
at org.ofbiz.core.entity.transaction.DBCPConnectionFactory.trackConnection(DBCPConnectionFactory.java:149)
at org.ofbiz.core.entity.transaction.DBCPConnectionFactory.getConnection(DBCPConnectionFactory.java:69)
at org.ofbiz.core.entity.ConnectionFactory.tryGenericConnectionSources(ConnectionFactory.java:69)
Caused by: java.net.SocketException: No buffer space available (maximum connections reached?): connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
Cause
JIRA can't create any new sockets when it's trying to talk to the database. This could be caused by another application on the same server as JIRA is leaking sockets (opening lots of sockets, but never closing them). For example, a real time database mirroring.
Resolution
- Temporary disable any application or applications' mechanism which might used up a lot of sockets.
- Run
netstat -n
on the server hosting JIRA (if Linux) and check whether sockets are being created excessively by applications.
Last modified on Mar 30, 2016
Powered by Confluence and Scroll Viewport.