Sunsea's Blog

CentOS下禁止运行screen或建立新窗口时更改窗口尺寸

xshell或putty之类的连接到centos 6下使用screen时会改变窗口的尺寸,非常烦人,可以通过如下方法修改使其不更改窗口尺寸。

编辑/etc/screenrc或~/.screenrc 加入下面的代码

# Change the xterm initialization string from is2=\E[!p\E[?3;4l\E[4l\E>
# (This fixes the "Aborted because of window size change" konsole symptoms found
#  in bug #134198)
termcapinfo xterm* 'is=\E[r\E[m\E[2J\E[H\E[?7h\E[?1;4;6l'

或者命令直接写入

cat >>/etc/screenrc<<EOF
# Change the xterm initialization string from is2=\E[!p\E[?3;4l\E[4l\E&gt;
# (This fixes the "Aborted because of window size change" konsole symptoms found
#  in bug #134198)
termcapinfo xterm* 'is=\E[r\E[m\E[2J\E[H\E[?7h\E[?1;4;6l'
EOF

当前页面是本站的「Google AMP」版。查看和发表评论请点击:完整版 »