- 论坛徽章:
- 0
|
Normal
0
7.8 磅
0
2
false
false
false
MicrosoftInternetExplorer4
st1\:*{behavior:url(#ieooui) }
/* Style Definitions */
table.MsoNormalTable
{mso-style-name:普通表格;
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";
mso-ansi-language:#0400;
mso-fareast-language:#0400;
mso-bidi-language:#0400;}
linux shell 远程协助
在windows xp下你可以使用远程协助,大体过程就是你向远端的专家发出协助请求,远端同意后,专家和你可以同时操作你的桌面。
linux黑乎乎的控制台下也可以实现远程协助功能:
第一步:确保系统中安装有tcl和expect这2个软件包。
将使用expect包中的脚本kibitz。
第二步:发出请求,同意请求,协助建立
先查看一下谁在线:
linux-dl180G6:/home/sxg/mnt # w
18:39:43 up
2:25, 3 users, load average: 0.00, 0.00, 0.00
USER
TTY LOGIN@ IDLE
JCPU PCPU WHAT
root
pts/0 16:27 0.00s
0.17s 0.00s w
root
pts/1 18:31 5:22
0.04s 0.04s -bash
假设其中pts/0是自己,pts/1是远端的某位专家。
发出请求,如下:
linux-dl180G6:/home/sxg/mnt # kibitz -tty pts/1 root
asking root to type: kibitz -5277
| (闪烁的光标)
此时专家控制台会出现如下:
linux-dl180G6:~ #
Message from root@linux-dl180G6 on pts/0 at 18:42 ...
Can we talk? Run: kibitz -5277
EOF
| (闪烁的光标)
此时,专家如果敲入提示的Run行:kibitz -5277,则会如下:
linux-dl180G6:~ #
Message from root@linux-dl180G6 on pts/0 at 18:42 ...
Can we talk? Run: kibitz -5277
EOF
kibitz -5277
Escape sequence is ^]
linux-dl180G6:/home/sxg/mnt #
可以看到,此时专家的当前目录变成了请求者的当前目录。
此时,请求者的屏幕显示如下:
linux-dl180G6:/home/sxg/mnt # kibitz -tty pts/1 root
asking root to type: kibitz -5277
Escape sequence is ^]
linux-dl180G6:/home/sxg/mnt #
第三步:开始协助
此时,请求者和专家在各自命令行上敲的任何字符,都会同步显示到对方的控制台上,不管是否敲了回车。
第四步:协助结束
任何一方敲入exit则协助结束。
本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/8754/showart_1999385.html |
|