linux断开已登录用户

Posted on Posted in 安全
Tips: 本文创建于2013年12月3日,已超过 2 年,内容或图片可能已经失效!

1、查找登录用户

[code lang="bash"]
ruofish@blackberry:~$ who
ruofish pts/1 2013-12-03 14:04 (192.168.1.177)
ruofish pts/2 2013-12-03 14:04 (192.168.1.177)
ruofish pts/3 2013-12-03 14:04 (192.168.1.177)
[/code]

2、通知该用户要端口他

[code lang="bash"]
ruofish@blackberry:~$ echo "close" > /dev/pts/2
[/code]

3、关闭该用户

[code lang="bash"]
ruofish@blackberry:~$ fuser -k /dev/pts/2
[/code]

» 转载请注明来源:若我若鱼 » linux断开已登录用户

Leave a Reply

Your email address will not be published. Required fields are marked *

13 + 16 =