I often have to run the update manager on a slow connection, and while reading my emails, I meanwhile would like to surf for 2 minutes in the web, then have the full bandwidth again for the update manager.
From the command line, I can suspend a running process with Ctrl+Z, aka suspend. But if I didn't start the program from the shell - can I do it with some signal and the kill
command?
I read the man page for signal
(man -a signal
), but there I didn't find a SIGSUSPEND, only SIGSTOP, SIGTERM, SIGINT and such - which is appropriate, or is there none?
For the general case you can stop (suspend a process or process group as below):
Control-Z is
kill pidnumber -SIGSTOP
to continue:
kill pidnumber -SIGCONT
Alternatively, to suspend an entire process group:
kill -groupnumber -SIGSTOP
and
kill -groupnumber -SIGCONT
Of course if you suspend a process with some element that is timed, it may not continue properly. In the use case mentioned, the repository server is timing data transfer acknowledgments, it can time-out the transfer because your client has 'gone away' or slow it down because there is 'network congestion'.
I certainly wouldn't suspend update-manager while it was updating my packages, either.