man screen
:
Screen is a full-screen window manager that multiplexes a physical ter?
minal between several processes (typically interactive shells). Each
virtual terminal provides the functions of a DEC VT100 terminal and, in
addition, several control functions from the ISO 6429 (ECMA 48, ANSI
X3.64) and ISO 2022 standards (e.g. insert/delete line and support for
multiple character sets). There is a scrollback history buffer for
each virtual terminal and a copy-and-paste mechanism that allows moving
text regions between windows.
When screen is called, it creates a single window with a shell in it
(or the specified command) and then gets out of your way so that you
can use the program as you normally would. Then, at any time, you can
create new (full-screen) windows with other programs in them (including
more shells), kill existing windows, view a list of windows, turn out?
put logging on and off, copy-and-paste text between windows, view the
scrollback history, switch between windows in whatever manner you wish,
etc. All windows run their programs completely independent of each
other. Programs continue to run when their window is currently not vis?
ible and even when the whole screen session is detached from the user's
terminal. When a program terminates, screen (per default) kills the
window that contained it. If this window was in the foreground, the
display switches to the previous window; if none are left, screen
exits.
Run Code Online (Sandbox Code Playgroud)
抛开技术解释,它与在常规 gnome 终端中创建选项卡有什么不同?
对于您可以从手册中执行的操作列表,我已经可以创建新选项卡、杀死选项卡、查看我的选项卡列表、在窗口之间切换。只是屏幕更方便吗?有人可以通俗地解释一下好处吗?
就在您 C&P 的手册页中:
Programs continue to run when their window is currently not visible and
even when the whole screen session is detached from the user's terminal.
Run Code Online (Sandbox Code Playgroud)
简而言之,当您的互联网连接中断时,您screen
的程序会继续运行,当您重新登录时,您可以重新连接到该会话。
在这可能有用的其他时候是您将使用 的时候nohup
,例如运行一个可以中断网络连接几秒钟的脚本(让您的会话终止并且您的脚本消失SIGHUP
可能使您的机器脱离网络)。
我不知道有多少人使用 screen 的“屏幕管理”功能,但我知道很多人在注销后分离程序以保持它们运行。
小智 5
如果您了解 microsoft 远程桌面的工作原理,您就很容易理解 screen 的工作原理。除了文本控制台外,几乎相同。因此,您可以从屏幕控制台分离(断开连接),然后重新连接到离开的会话。使用热键在屏幕、复制、粘贴、冻结、杀死等窗口之间切换。
因此,主要好处是,如果您突然与初始化屏幕的主机断开连接,则可以保存控制台状态,以便您可以重新连接回主机并重新连接上次会话。
screen -Dr(如果连接了其他人并连接到会话,则断开连接) Ca a Ca space Ca backspace For window rotate Ca c # to create new windows read man for more,但这是最有用的热键
归档时间: |
|
查看次数: |
1971 次 |
最近记录: |