Solved

Inactive sessions not clearing

Posted on 2004-10-07
3
4,530 Views
Last Modified: 2013-12-11
Hi,

Oracle 9.2.0.5 on solaris
Application is J2EE through application servers with connection pooling.

During stress testing, a large number of sessions were created. Though for last few days, only a few sessions have been active
but the inactive sessions are not clearing up. we are using "SQLNET.EXPIRE_TIME=10" in sqlnet.ora but it seems to be of no help in this scenario.

we are not using the default listener.

how can we make the inactive sessions clear in this environment ?

TIA,

grora
0
Comment
Question by:grora
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 7

Accepted Solution

by:
BobMc earned 250 total points
ID: 12248098
SQLNET.EXPIRE_TIME wont log off inactive sessions, it only detect sessions which have abnormally terminated, and cleans them up.

To terminate sessions after periods of inactivity, you would need to setup some profiles for your users, and set the idle_time parameter. Beware though that this doesnt fully terminate the client session either, but marks it as SNIPED. The session will stay like this until the user attempts to use the connection again, when they will be informed the session has been terminated, and any pending transactions will be rolled back.
If the user never retries the connection, it will remain SNIPED until you bounce the instance.

I dont know if there is something you can set on the application server that can resolve this for you.

HTH
Bob
0
 
LVL 23

Expert Comment

by:seazodiac
ID: 12248526
grora:

are you looking at this through v$session view?

this is ok, active sessions are NOT immediately cleaned out as they disconnected.
I find out this is true esp. when the session are opened via JDBC .
0
 
LVL 48

Expert Comment

by:schwertner
ID: 12256849
The NON DEAD sessions (if deleted) will be killed only by the first attempt for connection from the client. In fact these are live connections and there are clients on the other side. You can kill them due the long period of inactivity. The reason is that every session uses 2-5 MB RAM. 300 sessions = 0.8 - 1.5 GB RAM!!!!

"SQLNET.EXPIRE_TIME=10" sends probe packages to the clients and waits for answer. If there is no answer, it kills the session immediatelly.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Configuring and using Oracle Database Gateway for ODBC Introduction First, a brief summary of what a Database Gateway is.  A Gateway is a set of driver agents and configurations that allow an Oracle database to communicate with other platforms…
Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database

724 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question