KILL INACTIVE SESSIONS IN R12
*****************KILL
INACTIVE SESSIONS IN R12*********
[oracle@dev1211]$cd /oracle/VIS/apps/apps_st/appl
[oracle@dev1211 appl]$ . APPSVIS_dev1211.env
[oracle@dev1211 appl]$ sqlplus
SQL*Plus: Release 10.1.0.5.0 - Production on Wed Apr
4 05:21:44 2012
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Enter user-name: apps
Enter password: apps
Connected to:
Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 -
Production
With the Partitioning, OLAP, Data Mining and Real
Application Testing options
SQL>
SQL>spool on
SQL> spool /home/oracle/session.sql
SQL>select 'alter system kill session
'''||sid||','||serial#||''' immediate;'
from
v$session
where
status='INACTIVE';
SQL>spool off
SQL> @/home/oracle/session.sql
SQL>select 'alter system kill session
'''||sid||','||serial#||''' immediate;'
from
v$session
where
status='INACTIVE';
SQL> select 'alter system kill session
'||''''||sid||','||serial#||''' immediate;',(sysdate-logon_time)/5 from
V$session;
Total Number Of Active Sessions: -
[oracle@appsr12]$ ps -ef|grep -i applvis|wc -l
[oracle@appsr12]$ ps -ef|grep -i applvis|wc -l
No comments:
Post a Comment