stop

Official Description

Stops background jobs.

Syntax

stop %job_number or pid
				

Options

None

Oddities

The stop command is an alias for kill -s STOP.

Example

$ buzz&                      # Create two background jobs
[1]     1181
$ buzz&
[2]     1182
$
$ jobs
[2] +  Running                 buzz&
[1] -  Running                 buzz&
$
$ stop %1                    # Stop job #1
[1] + Stopped (SIGSTOP)        buzz&
$
$ jobs -l
[1] + 1181      Stopped (SIGSTOP)        buzz&
[2] - 1182       Running                 buzz&
$
$ stop 1182                  # Stop pid # 1182
[2] + Stopped (SIGSTOP)        buzz&
$
				

Get Korn Shell Programming by Example now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.