
On 6/01/2015 11:39 AM, Carl Turney wrote:
On 06/01/15 11:09, Russell Coker wrote:
kill -stop will suspend a process and kill -cont will continue it. It wouldn't be difficult to write a script that runs kill -stop and kill -cont in a loop.
Ah. I grasp the underlying concept, and know a bit about ps and kill.
If only I weren't so very damned rusty on other Linux bash commands, and writing scripts with loops and conditionals.
It's really quite simple and a great solution. ps -fe|grep someprocess You'll get the process id (PID) in the second column. Then you could set up a couple of aliases to make it simple. alias stop_tb='kill -STOP nnnn' alias start_tb='kill -CONT nnn' Now, so long as the PID doesn't change, then you can simply run the commands quickly as desired. stop_tb start_tb Cheers A.