in NT , there is a utility call orakill which can release the resource owned by session . Make a trial please .
to: developer2002 (1)如果已经得到了这个pid,那么杀死该进程的语句怎么写? (2)为什么我在kill session 'sid,serrial#'并提示成功之后,该session还会在v$session中出现呢?to black_snail: where can i find the orakill and how to user it,could u tell me more?3x very much!
Win NT/2000 is a thread based Operating System and not process based Operating System like Unix. Oracle user and background processes are not multiple processes but, threads with in oracle.exe process. 'orakill' is oracle provided utility to kill a particular resource intensive thread under oracle.exe process. For help type in at the DOS prompt C:\>orakill /? The following query can be used to get the sid, thread id of a particular resource intensive thread.SQL> select sid, spid as thread, osuser, s.program 2 from sys.v_$process p, sys.v_$session s 3 where p.addr = s.paddr;SID THREAD OSUSER PROGRAM -------- --------- --------------- ------------------------------------- 1 000C5 UNKNOWN ORACLE73.EXE 2 0013F UNKNOWN ORACLE73.EXE 3 00140 UNKNOWN ORACLE73.EXE 4 0005F UNKNOWN ORACLE73.EXE 5 0011C UNKNOWN ORACLE73.EXE 6 0009A UNKNOWN ORACLE73.EXE 7 00101 8 000C0 12 00148 SYSTEM D:\ORANT805\agentbin\DBSNMP.EXE 18 001FC scott SQLPLUS.EXE 9 001F2 adam C:\WINNT\Profiles\All Users\Start Menu\AFF_PFC.LNK 36 00206 SVRMGR.EXE 31 000E1 cathy AFFAIRS.EXE 15 00204 Julie C:\Documents and Settings\julie\Start Menu\Programs\AFFS.lnk Say the query from user scott is consuming lot resources and it can be killed by running orakill utility as follows.C:\>orakill 18 001FC请将此贴结为FAQ
(1)如果已经得到了这个pid,那么杀死该进程的语句怎么写?
(2)为什么我在kill session 'sid,serrial#'并提示成功之后,该session还会在v$session中出现呢?to black_snail:
where can i find the orakill and how to user it,could u tell me more?3x very much!
或者
KILL -9 PID
(以上均在操作系统提示符下进行)
2 from sys.v_$process p, sys.v_$session s
3 where p.addr = s.paddr;SID THREAD OSUSER PROGRAM
-------- --------- --------------- -------------------------------------
1 000C5 UNKNOWN ORACLE73.EXE
2 0013F UNKNOWN ORACLE73.EXE
3 00140 UNKNOWN ORACLE73.EXE
4 0005F UNKNOWN ORACLE73.EXE
5 0011C UNKNOWN ORACLE73.EXE
6 0009A UNKNOWN ORACLE73.EXE
7 00101
8 000C0
12 00148 SYSTEM D:\ORANT805\agentbin\DBSNMP.EXE
18 001FC scott SQLPLUS.EXE
9 001F2 adam C:\WINNT\Profiles\All Users\Start Menu\AFF_PFC.LNK
36 00206 SVRMGR.EXE
31 000E1 cathy AFFAIRS.EXE
15 00204 Julie C:\Documents and Settings\julie\Start Menu\Programs\AFFS.lnk
Say the query from user scott is consuming lot resources and it can be killed by running orakill utility as follows.C:\>orakill 18 001FC请将此贴结为FAQ