On Windows for each instance all oracle sessions are thread based and are part of one Oracle process (oracle.exe), so killing oracle.exe would crash your entire instance. Therefore using the utility orakill.exe one can kill user’s session. Using the following SQL one can find the thread id of the oracle process.
SQL> SELECT a.username, a.osuser, b.spid ThreadID, a.sid, a.serial# FROM v$session a, v$process b WHERE a.paddr = b.addr AND a.username IS NOT NULL;
USERNAME OSUSER ThreadID PROGRAM
————— —————————— ——— ——————————
SYS oracle 2990 rman (TNS V1-V3)
SCOTT mary 1384
So using orakill kill session mary’s session.
c:> orakill TESTDB 1384
Leave a comment