You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Sridhar Jena (JIRA)" <ji...@apache.org> on 2018/03/01 02:22:00 UTC
[jira] [Commented] (DERBY-6985) Connection never released from
Derby
[ https://issues.apache.org/jira/browse/DERBY-6985?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16381402#comment-16381402 ]
Sridhar Jena commented on DERBY-6985:
-------------------------------------
Yes this is valid one. This concept is called DCD(Dead Connection Detection).Now a days every database has its own DCD management to clean up the dead connections at server side.
if you will check in Oracle they have the sqlnet_expire_time (in sqlnet.ora file) and the dead connection cleanup utility. We can specify a timeout interval by placing the sqlnet_expire_time parameter in your sqlnet.ora file. For example, setting sqlnet_expire_time=2 will poll the SQL*Net client every two minutes and disconnect the session if there is no activity.
If the operating system supports TCP keep-alive tuning then Oracle Net automatically uses the new method. The new mechanism is supported on all platforms except on Solaris.
The following parameters are associated with the TCP keep-alive probes:
TCP_KEEPIDLE – specifies the timeout of no activity until the probe is sent. The parameter takes value from SQLNET.EXPIRE_TIME.
TCP_KEEPCNT – number of keep-alive probes to be sent, it is always set to 10.
TCP_KEEPINTVL – specifies the delay between probes if a keep-alive packets are sent and no acknowledgment is received, it is always set to 6.
In derby admin guide it has mentioned only about "derby.drda.keepAlive property" but no where mentioned how can "keepAliveTimeOut" will be configured as default is more than two hours ? Again question is from where it is taking default more than 2 hours if it is not configured ?
Thanks,
> Connection never released from Derby
> ------------------------------------
>
> Key: DERBY-6985
> URL: https://issues.apache.org/jira/browse/DERBY-6985
> Project: Derby
> Issue Type: Bug
> Affects Versions: 10.14.1.0
> Reporter: Satyabrata Mohanty
> Priority: Major
> Attachments: Derby_Open_Connection.png
>
>
> Hi,
> Below is the complete description of the issue,
> * Running a java application which creates a good number of connections with derby on the machine X.
> * We are running the derby database server on the machine lets say Y.
> * We explicitly block the listening of 1527 port of system X traffics on system Y in the network until it thrown connection exception and then again established the network between the two systems.
> * After the java application has finished execution we found there are still some connections remained open in derby.
> * We can see open connections in derby although we have terminated the java application.
> * We have restarted derby to free up these connection.
> * Concern here is, how these connection are generated, is these connections are broken /stale connection made during the network reset, if YES then, how to these connection will be auto deleted or handled in derby ?
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)