If you want to kill on own your session in Linux. For example: If you login as oracle and your session got hung.
[oracle@testbox exports]$ who -u
root tty1 Oct 11 00:24 old 6396
oracle pts/0 Oct 30 15:03 00:09 27795 (10.0.0.61)
root pts/1 Oct 30 11:07 23:57 29527 (10.0.0.37)
oracle pts/2 Oct 31 11:33 . 3476 (10.0.0.61)
kill and killall are not working
[oracle@testbox ~]$ kill -9 27795
-bash: kill: (27795) - Operation not permitted
[oracle@testbox exports]$ killall -9 27795
27795: no process killed
Solution
You need to get right PID to kill session.
[oracle@testbox exports]$ps ax | grep -i oracle
23945 ? Ss 2:00 oracleclpro1 (LOCAL=NO)
27795 ? Ss 0:00 sshd: oracle [priv]
27832 ? S 0:00 sshd: oracle@pts/0
30206 ? Ss 4:29 oraclepriv1 (LOCAL=NO)
32617 ? Ss 0:00 oracletest1 (LOCAL=NO)
[oracle@testbox exports]$ kill -9 27832
You are now all set.
No comments:
Post a Comment