通过telnet发送到Fedora服务器的Ctrl-Z不会停止该过程 [英] Ctrl-Z sent to Fedora server over telnet does not stop the process

查看:98
本文介绍了通过telnet发送到Fedora服务器的Ctrl-Z不会停止该过程的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

目标:

我正在开发一个iOS终端仿真器,用于通过telnet协议访问我的Unix服务器.我正在针对AIX和Fedora Linux进行测试.

I am working on an iOS terminal emulator for accessing my Unix server through the telnet protocol. I am testing against both AIX and Fedora Linux.

问题:

如果我将Ctrl-Z(ASCII 26)发送到AIX服务器,则其行为与预期的一样:我返回了一个stopped programname之类的字符串,然后我发送的所有其他字符都得到了回显.

If I send Ctrl-Z (ASCII 26) to the AIX server, it behaves as expected: I get back a string like stopped programname, and then any further characters I send get echoed back.

当我将其发送到Fedora服务器时,直到第二次发送Ctrl-Z时,我都没有回声.该程序在Fedora机器上的Bash下运行.

When I send it to the Fedora server, I get no echo-back until I send Ctrl-Z a second time. The program is running under Bash on the Fedora machine.

为什么我会看到这种行为上的差异?

Why am I seeing this difference in behavior?

推荐答案

您必须拨打2个电话:

  1. 停止该过程

  1. Stopping that process

kill -SIGSTOP 'pgrep process_name'

继续该过程

kill -SIGCONT 'pgrep process_name'

SIGSTOP告诉进程保持",而SIGCONT告诉进程 从你上次停下来的地方捡起"

SIGSTOP tells a process to "hold on" and SIGCONT tells a process to "pick up where you left off"


看看,是否有帮助.


See, if that help.

这篇关于通过telnet发送到Fedora服务器的Ctrl-Z不会停止该过程的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆