wikiti
4/10/2017 - 10:00 AM

Pause and resume a process

Pause and resume a process

# Find the PID of some process:
ps -aux | grep some-process-name

# Pause a process with a PID
kill -TSTP $pid

# Resume a process with a PID
kill -CONT $pid

# Find the PGID of some process:
ps -efj | grep some-process-name

# Pause all process with the same PGID
# (Notice the negative value!)
kill -TSTP -$gpid

# Resume all process with the same PGID
# (Notice the negative value!)
kill -CONT -$gpid

# More information:
# - https://www.ibm.com/support/knowledgecenter/ssw_i5_54/apis/sigkill.htm
# - http://unix.stackexchange.com/questions/2107
# - http://unix.stackexchange.com/questions/82724