After Upgrade Jira from v6.3 to 8.4.3 it has too many CLOSE_WAIT
Asked by Steffen Stamprath:

I Upgraded my Jira from v6.3 to 8.4.3 and now the TCP CLOSE_WAIT are too many. Currently it has 2095 CLOSE_WAIT (After 3 days running).

What do I wrong?

621x 111.0.0.1:8080  
793x 111.30.10.11:80 #jira (localhost)  
497x 111.30.10.32:7990 #bitbucket  
156x 111.30.10.65:80 #confluence


Answers:
author: prudhvi_mudunuri
body: Any Luck on this? We have the same issue


author: Steffen Stamprath
body: Anybody an idea?


author: Kiran Panduga {Appfire}
body: Hi [@Steffen Stamprath](/t5/user/viewprofilepage/user-id/853378) ,

Can you verify the database connections? looks like the JIRA running out of database connections.

Try to increase the database connections and then verify.

Also, one need to review the JIRA logs for a detail look.

Thanks,

Kiran.

comments: author: Steffen Stamprath
body: We mus currently restart the system once a day.

Maybe this data can help you:

![Bildschirmfoto 2020-01-08 um 07.43.42.png](https://community.atlassian.com/t5/image/serverpage/image-id/78153i2F4EE71229565D82/image-size/large?v=v2&px=999 "Bildschirmfoto 2020-01-08 um 07.43.42.png")

dbconfig.xml

```
<?xml version="1.0" encoding="UTF-8"?>
<jira-database-config>
    <name>defaultDS</name>
    <delegator-name>default</delegator-name>
    <database-type>oracle10g</database-type>
    <jdbc-datasource>
        <url>XXXX</url>
        <driver-class>oracle.jdbc.OracleDriver</driver-class>
        <username>XXX</username>
        <password>XXX</password>
        <pool-min-size>20</pool-min-size>
        <pool-max-size>20</pool-max-size>
        <pool-max-wait>30000</pool-max-wait>
        <pool-max-idle>20</pool-max-idle>
        <pool-remove-abandoned>true</pool-remove-abandoned>
        <pool-remove-abandoned-timeout>300</pool-remove-abandoned-timeout>
        <validation-query>select 1 from dual</validation-query>
        <min-evictable-idle-time-millis>60000</min-evictable-idle-time-millis>
        <time-between-eviction-runs-millis>300000</time-between-eviction-runs-millis>
        <pool-test-while-idle>true</pool-test-while-idle>
        <pool-test-on-borrow>false</pool-test-on-borrow>
     </jdbc-datasource>
</jira-database-config>
```

Log:

```
Caused by: java.sql.SQLException: Cannot get a connection, pool error Timeout waiting for idle object
at org.apache.commons.dbcp2.PoolingDataSource.getConnection(PoolingDataSource.java:142)
at org.apache.commons.dbcp2.BasicDataSource.getConnection(BasicDataSource.java:1533)
at org.ofbiz.core.entity.transaction.DBCPConnectionFactory$1.call(DBCPConnectionFactory.java:285)
at org.ofbiz.core.entity.transaction.DBCPConnectionFactory$1.call(DBCPConnectionFactory.java:283)
at org.ofbiz.core.entity.jdbc.interceptors.connection.ConnectionTracker.trackConnection(ConnectionTracker.java:48)
Caused by: java.util.NoSuchElementException: Timeout waiting for idle object
at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:449)
at org.apache.commons.pool2.impl.GenericObjectPool.borrowObject(GenericObjectPool.java:363)
at org.apache.commons.dbcp2.PoolingDataSource.getConnection(PoolingDataSource.java:134)
... 320 more
```


Tags: confluence-server

jira

network

server