Thursday, January 10, 2008

How to setup Session Timeout in Oracle AS 10g?

As the Middleware in general is a set of tools that work together in a common infrastructure, it is important to understand every component/tool may have separate session management due to the way and where it operates in the whole technology stack. Here are the various ways one can setup the session timeout. Some cases we may need to set more than one place to make it work together.


OC4J Application level (Custom applications in particular)
Change the session-timeout value in web.xml file.

session-config>
session-timeout>60 session-timeout>
session-config>

Once done, deploy and test.

Oracle Applications 11i
System Profile option ICX:Session Timeout 30 (Minutes)
zone.properties file session.timeout=180000 (Milliseconds=30 Minutes)

OID
To set the interval in ODM select the server, then the Query Optimization tab, LDAP Connection Timeout. Then set the value to 30 (default is 0, no timeout). The value is in minutes. Remember, the value should be set to less than any firewall or load balancer timeout.

In ODM select the server, then the System Operational Attributes tab, Statistics Collection Interval is set to 15. The default is 60 minutes. This value should be set to about half the connection timeout.

SSO
a) Navigate to http://:port/pls/orasso
b) Login with an administration account
c) Press 'SSO Server Administration'
d) Press 'Edit SSO Server Configuration'
e) In the section 'Single Sign-On Session Policy', change the Single Sign-on Session Duration from 8Hrs to .5 Hr (30 Min) à this must match 11i Timeout

ORASSO
Set Global Inactivity Timeout – Login as ORASSO and run $ORACLE_HOME/sso/admin/plsql/sso/ssogito.sq set the “inactivity_period” in Minutes (Default 15 min, To disable timeout set inactivity period to 0)

Set connectionIdleTimeout = 30 (default 120 min) in $ORACLE_HOME/sso/conf/policy.properties

Set OssoIdleTimeout on (Default off) in $ORACLE_HOME/Apache/Apache/conf/mod_osso.conf


Bounce the services on 10gAS and 11i

Use whichever is applicable for your environment and needs

opmnctl stopproc process-type=HTTP_Server
opmnctl startproc process-type=HTTP_Server

opmnctl stopproc process-type=OC4J_OID
opmnctl startproc process-type=OC4J_OID

opmnctl status -l

adapcctl.sh stop
adapcctl.sh start