Linux强制让指定用户下线

强制让指定用户下线

who
ps -ef | grep pts
kill 这个进程号

[root@L170 ~]# who
jsb      pts/1        2013-05-22 10:50 (192.168.30.180)
root     pts/5        2013-05-22 11:21 (192.168.31.193)
[root@L170 ~]# ps -ef | grep pts
jsb      29135 29133  0 10:50 ?        00:00:00 sshd: jsb@pts/1
jsb      29136 29135  0 10:50 pts/1    00:00:00 -bash
root     29427  2622  0 11:21 ?        00:00:00 sshd: root@pts/5
root     29429 29427  0 11:21 pts/5    00:00:00 -bash
root     29454 29429  0 11:21 pts/5    00:00:00 ps -ef
root     29455 29429  0 11:21 pts/5    00:00:00 grep pts
[root@L170 ~]# kill -9 29135

 

你可能感兴趣的:(Linux强制让指定用户下线)