Chinaunix首页 | 论坛 | 博客
  • 博客访问: 4450548
  • 博文数量: 1214
  • 博客积分: 13195
  • 博客等级: 上将
  • 技术积分: 9105
  • 用 户 组: 普通用户
  • 注册时间: 2007-01-19 14:41
个人简介

C++,python,热爱算法和机器学习

文章分类

全部博文(1214)

文章存档

2021年(13)

2020年(49)

2019年(14)

2018年(27)

2017年(69)

2016年(100)

2015年(106)

2014年(240)

2013年(5)

2012年(193)

2011年(155)

2010年(93)

2009年(62)

2008年(51)

2007年(37)

分类: LINUX

2011-06-19 21:32:59

文章来源:

ssh 连接到一半,想回到本地,可以 suspend ssh 会话。
输入 ~+ ,回到本地:

jaseywang@A ~$: ~^Z  [suspend ssh]
[1]+  Stopped                 ssh jaseywang@192.168.1.2

jaseywang@B ~$:

回到本地了。

jaseywang@B ~$: jobs
[1]+  Stopped                 ssh jaseywang@192.168.1.2

继续进行远程会话:

jaseywang@B ~$: fg %1
ssh jaseywang@192.168.1.2

jaseywang@A ~$:

上面的 ~ 符号其实就是 -e 选项的默认参数:

-e escape_char
             Sets  the escape character for sessions with a pty (default: `~'
             ) .  The escape character is only recognized at the beginning of
             a  line.   The  escape character followed by a dot (`.')  closes
             the connection; followed by control-Z suspends  the  connection;
             and followed by itself sends the escape character once.  Setting
             the character to “none'' disables any  escapes  and  makes  the
             session fully transparent.

阅读(1224) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~