|
-
Hi everyone,
I kicked several procedures off through sqlplus (multiple sessions). A few minutes later I realized that I kicked one of them by mistake and would like to kill that session.
Is there any way of doing it? I gues I'd break my question into 2 parts:
-Is there any way of seeing what procedures are running at the moment in the database?
-How do I find a session id for a scecific statement/procedure running?
Thank you.
-
ps -ef|grep oracle --> tells you which oracle processes are running. Find the process and issue: kill -9 process_no.
-
Thanks Halo.
I wish I run on Unix. But that is not the case. I run Nt. I cannot use a -grep command.
-
Try the task manager on NT and Cancel that session(which calls sql*plus)
Soumya
still learning
-
yes, that is what I am trying to do. The problem is I don't know how to identify the session I need to kill. When you go to session manager it shows you all the sessions connected to the db. I need to kill a specific session. I am wondering if there is a way to find out what sql statement/process each session running and then kill the one I kicked off by mistake.
Thank you for your help.
-
Mary you can choose one of those 2 metods.
1 - it's the simplest if you have installed OEM. Run the top session monitor from the OEM and the with a right click on the session you wanto to kill choose kill and do it!
2 - from sql*Plus run the follwing query
SELECT username, sid, serial#
FROM v$session;
for example if you have thi result
USERNAME SID SERIAL#
------------------------------ --------- ---------
SYSTEM 7 7
USER1 5 25
and you want to kill USER1 then run the current statement:
ALTER SYSTEM KILL SESSION '5,25';
you can re-run the first query to verify the operation.
I hope this can help you.
Bye
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|