freeze background process

#freeze background process
kill -STOP $PID

#unfreeze the proccess
kill -CONT $PID

example of Linux process pause

kill -STOP 169822
kill -STOP 178327

Status in ps 

root@server3:~# ps -waux |grep -e COMMAND -e ffmpeg  |grep -v grep
USER         PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
www-data  169821  0.0  0.0   2576  1536 ?        S    13:51   0:00 sh -c ffmpeg -threads 3 -i /tmp/oc_tmp_OhptOg-.MOV  -movflags use_metadata_tags -map_metadata 0 -vf zscale=t=linear:npl=550,format=gbrpf32le,tonemap=tonemap=mobius:desat=0,zscale=p=bt709:t=bt709:m=bt709:r=tv,format=yuv420p -vcodec libx264 -preset VerySlow -strict -2 /tmp/oc_tmp_OhptOg-_out_.mp4
www-data  169822  659  8.3 7759376 5459868 ?     Tl   13:51 1620:40 ffmpeg -threads 3 -i /tmp/oc_tmp_OhptOg-.MOV -movflags use_metadata_tags -map_metadata 0 -vf zscale=t=linear:npl=550,format=gbrpf32le,tonemap=tonemap=mobius:desat=0,zscale=p=bt709:t=bt709:m=bt709:r=tv,format=yuv420p -vcodec libx264 -preset VerySlow -strict -2 /tmp/oc_tmp_OhptOg-_out_.mp4
www-data  178326  0.0  0.0   2576  1408 ?        S    17:45   0:00 sh -c ffmpeg -threads 3 -i /tmp/oc_tmp_MHkD3c-.MOV  -movflags use_metadata_tags -map_metadata 0 -vf zscale=t=linear:npl=550,format=gbrpf32le,tonemap=tonemap=mobius:desat=0,zscale=p=bt709:t=bt709:m=bt709:r=tv,format=yuv420p -vcodec libx264 -preset VerySlow -strict -2 /tmp/oc_tmp_MHkD3c-_out_.mp4
www-data  178327  122  2.2 3649964 1467392 ?     Tl   17:45  14:37 ffmpeg -threads 3 -i /tmp/oc_tmp_MHkD3c-.MOV -movflags use_metadata_tags -map_metadata 0 -vf zscale=t=linear:npl=550,format=gbrpf32le,tonemap=tonemap=mobius:desat=0,zscale=p=bt709:t=bt709:m=bt709:r=tv,format=yuv420p -vcodec libx264 -preset VerySlow -strict -2 /tmp/oc_tmp_MHkD3c-_out_.mp4

resume linux process

kill -CONT 169822
kill -CONT 178327


  • No labels