Wednesday, August 7, 2019

kill ssh session

kill ssh session

# ps -aux | grep ssh

You will see the result like this :-

root     21906  0.2  0.0 161472  6228 ?        Ss   10:13   0:01 sshd: root@pts/0
root     22127  0.0  0.0 112864  4344 ?        Ss   10:14   0:00 /usr/sbin/sshd -D
root     24169  0.0  0.0 158748  5276 ?        Ss   10:18   0:00 sshd: unknown [priv]
sshd     24170  0.0  0.0 112864  2224 ?        S    10:18   0:00 sshd: unknown [net]
root     24227  0.0  0.0 156724  5224 ?        Ss   10:18   0:00 sshd: unknown [priv]
sshd     24228  0.0  0.0 112864  2228 ?        S    10:18   0:00 sshd: unknown [net]
root     24291  0.0  0.0 158748  5280 ?        Ss   10:19   0:00 sshd: unknown [priv]
sshd     24292  0.0  0.0 112864  2228 ?        S    10:19   0:00 sshd: unknown [net]
root     24317  0.0  0.0 156724  5220 ?        Ss   10:19   0:00 sshd: unknown [priv]


# kill -9 (your pid)

hope this will helps you

0 comments: