在 Ubuntu 终端中将进程从后台移动到前台时出现问题

Issue when moving process from background to foreground in Ubuntu Terminal

我从终端在后台启动了几个进程。

lars@UbuntuVM:~$ xeyes &
[1] 8553
lars@UbuntuVM:~$ xclock -update 1 &
[2] 8554
lars@UbuntuVM:~$ jobs
[1]-  Running                 xeyes &
[2]+  Running                 xclock -update 1 &

任务是把其中一个拉到前台,挂起,再拉回后台。但是,当我将其中一个带到前台时,我无法输入任何新命令。如果我输入 ^C,它只会一起终止整个过程。

lars@UbuntuVM:~$ fg %1
xeyes
How
do
I
get 
back
from
here?

那么当移动到前台时如何继续挂起当前进程?

用于将前台进程发送到后台的正确组合键是 ^Z,而不是 ^C。有关详细信息,请参阅 job control 上的 Bash 手册。