|
|
You can only suspend a job that was started in your current shell. To suspend a running job, press <Ctrl>Z (or the current defined suspend key). The job will stop running, but will remain available (and can be continued).
For example:
$ sort bigfile.dat >bigfile.out
<Ctrl>Z
[1] + Stopped sort bigfile.dat>bigfile.out
If <Ctrl>Z does not work, your suspend key may not
be set up correctly. To identify the suspend key, use the following
command:
$ stty -a | grep susp
swtch = ^@;susp = ^Z;start = ^Q;stop = ^S;
This command line looks for the word susp
in the
stty settings. If it is present, it will tell you the
current suspend key. If it is not present, or if you want to change
it to another key, you can modify it using the stty
command. For example, to make <Ctrl>Q the suspend key,
enter the following:
$ stty susp ^Q
(The ``^Q'' is entered by typing a caret (^) followed by a
letter ``Q''.)