设为首页 加入收藏

TOP

Linux下screen命令的使用(二)
2015-11-21 01:31:51 来源: 作者: 【 】 浏览:2
Tags:Linux screen 命令 使用
=ts/2 term=0 exit=0 root + pts/3 2015-03-19 22:33 . 5830 (192.168.80.1) root + pts/4 2015-03-19 22:42 00:11 5851 (192.168.80.1:S.0)---->注意此处 [root@rhel63single ~]# screen -ls There is a screen on: 5850.lei2 (Attached) 1 Socket in /var/run/screen/S-root. [root@rhel63single ~]# ps -ef | grep 5851---->注意此处 root 5851 5850 0 22:33 pts/4 00:00:00 /bin/bash root 5974 5830 0 22:56 pts/3 00:00:00 grep 5851 [root@rhel63single ~]# ps -ef | grep 5850---->注意此处 root 5850 1 0 22:33 ? 00:00:00 SCREEN -dmS lei2 ---->注意此处 root 5851 5850 0 22:33 pts/4 00:00:00 /bin/bash ---->注意此处 root 5883 5810 0 22:42 pts/2 00:00:00 screen -r 5850 [root@rhel63single ~]#

八、检查当前的提示符是否处于screen的session中:

按ctrl,再按a,再按t

此时,在左下角会显示:“22:45:06 Mar 19 rhel63single 0.00 0.00 0.00” 字样
格式为:当前时间,日期,主机名,负载情况


九、杀掉screen中的其他session

[root@rhel63single ~]# kill -9 5850
[root@rhel63single ~]# screen -ls
There is a screen on:
        5850.lei2       (Dead ???)
Remove dead screens with 'screen -wipe'.
1 Socket in /var/run/screen/S-root.

[root@rhel63single ~]# screen -wipe
There is a screen on:
        5850.lei2       (Removed)
1 socket wiped out.
No Sockets found in /var/run/screen/S-root.

[root@rhel63single ~]# screen -ls
No Sockets found in /var/run/screen/S-root.

[root@rhel63single ~]# 

然后,被杀掉的session 有提示:

[root@rhel63single ~]# 
Suddenly the Dungeon collapses!! - You die...
[root@rhel63single ~]# 




首页 上一页 1 2 下一页 尾页 2/2/2
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
分享到: 
上一篇《Redis设计与实现》学习笔记-Lua.. 下一篇Mycat水平分表,垂直分表实践(2)

评论

帐  号: 密码: (新用户注册)
验 证 码:
表  情:
内  容: