我最近设置了一台新的 FreeBSD 机器,但似乎无法通过 Emacs Tramp 连接。它停留在“Tramp:在'broken.example.com'上找到远程shell提示符”。(主机名因匿名而改变)
正如我所看到的那样,我将调试提高到 10 并且它卡在了这个命令上。
stty icanon erase ^H cols 32767
它不断循环执行此命令。完整的日志可以在http://depht.com/temp/emacs-tramp-broken.example.com.txt下载
'stty -a' 来自 broken.example.com。
speed 9600 baud; 65 rows; 32767 columns;
lflags: icanon isig iexten echo echoe -echok echoke -echonl echoctl
-echoprt -altwerase -noflsh -tostop -flusho -pendin -nokerninfo
-extproc
iflags: -istrip icrnl -inlcr -igncr ixon -ixoff ixany imaxbel -ignbrk
brkint -inpck -ignpar -parmrk
oflags: opost onlcr -ocrnl tab0 -onocr -onlret
cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -dsrflow
-dtrflow -mdmbuf
cchars: discard = ^O; dsusp = ^@; eof = ^D; eol = <undef>;
eol2 = <undef>; erase = ^H; erase2 = ^T; intr = ^C; kill = ^U;
lnext = ^V; min = 1; quit = ^\; reprint = ^R; start = ^Q;
status = ^T; stop = ^S; susp = ^Z; time = 0; werase = ^W;
我有一台稍旧的 OpenBSD 机器,同样的 Emacs Tramp 客户端可以很好地工作,working.example.com。与这台机器的连接日志位于http://depht.com/temp/emacs-tramp-working.example.com.txt
'stty -a' 来自 working.example.com
speed 9600 baud; 65 rows; 166 columns;
lflags: icanon isig iexten echo echoe -echok echoke -echonl echoctl
-echoprt -altwerase -noflsh -tostop -flusho pendin -nokerninfo
-extproc -xcase
iflags: -istrip icrnl -inlcr -igncr -iuclc ixon -ixoff ixany imaxbel
-ignbrk brkint -inpck -ignpar -parmrk
oflags: opost onlcr -ocrnl -onocr -onlret -olcuc oxtabs -onoeot
cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -mdmbuf
cchars: discard = ^O; dsusp = ^@; eof = ^D; eol = <undef>;
eol2 = <undef>; erase = ^H; intr = ^C; kill = ^U; lnext = ^V;
min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T;
stop = ^S; susp = ^Z; time = 0; werase = ^W;
我弄乱了 broken.example.com 上的 stty 设置以模仿 working.example.com 的设置,但没有成功。我不太了解所有的 stty 设置。一种可能的攻击途径是“stty pendin”,stty 的手册页称其与 icanon 相关。但是,我无法在 broken.example.com 上设置 -pendin。通过登录脚本或手动登录后执行的“stty -pendin”不会导致设置“-pendin”。
在这一点上,我完全迷失了,任何帮助将不胜感激。先感谢您!!