命令screen
更新:HHH   时间:2023-1-7


-S sockname   创建一个会话
-r            进入一个detached会话 
-list         查看会话列表

会话状态:
1.detached 无人
2.Attached 有人

退出会话,会话后台执行: crtl+a+d

 

建立窗口

screen –S chaoren

crtl+a+d退出,会话后台执行

[root@mds ~]# screen   -S chaoren
[detached]
[root@mds ~]#

 

新开窗口执行

[root@mds ~]# screen  -list
There is a screen on:
    30564.chaoren    (Attached)
1 Socket in /var/run/screen/S-root.

前面退出查看

[root@mds ~]# screen  -list
There is a screen on:
    30730.chaoren    (Detached)
1 Socket in /var/run/screen/S-root.

[root@mds ~]#

返回系统运维教程...