How to kill a session quick
I used to ran into this problem:
A user logs in and locks several tables. Even if I use "Aler system kill session ...", the session is only marked as "killed.". How do I make sure the session is killed quickly? Someone will suggest me to re-start the instance. But sometimes that's not an option.
Re: How to kill a session quick
Quote:
Originally posted by dba_admin
I used to ran into this problem:
A user logs in and locks several tables. Even if I use "Aler system kill session ...", the session is only marked as "killed.". How do I make sure the session is killed quickly? Someone will suggest me to re-start the instance. But sometimes that's not an option.
The session is killed immediately when you kill an active session. Marked as killed comes when you kill an inactice session. Marked for kill does not mean, the user is not killed. The user is killed, but Oracle marks the status as "killed" and the user details can be seen in v$session view. It does not mean, the user is still connected. The user is informed "session killed" when the user sub sequently queries the database and the user details are removed from v$session.
It's like
ACTIVE session killed:
1. One active user is killed.
2. User is disconnected from database and a message is displayed to user end terminal.
3. User details are not available in v$session view.
INACTIVE session killed:
1. One inactive user is killed.
2. User is disconnected from database.
3. User is not informed about disconnection.
4. User details are available in v$session view with status as "KILLED"
5. User tries to query the database and is informed of killing.
6. User details are rfemoved from v$session view.
All these things are for a typical dedicated server database. Things may vary for MTS. And there is something to do with inband and outband connections. These connection types make a lot of difference when we kill the session.
Can somebody refresh me with the details of these breaks??? :cool: