When I want to kill a process via System Monitor I am presented with 2 quick ways, Kill Process and End Process. What is the difference between these two?
Per the System Monitor manual, you should normally use "End Process", and only if that fails use "Kill Process":
You usually terminate a process only if you cannot end the process normally as described in To End a Process.
On a technical level this makes me think that End Process sends a SIGQUIT, which allows the process to trap and perform cleanup if needed, but if that fails, Kill Process should send a SIGKILL which should violently terminate the process, without chance of recovery. Use sparingly!
I was curious too, so I just browsed through the source code and found the below in application.cpp. There is more to this code but I think these correlate to the options, at least for System Monitor 184.108.40.206 through 3.19.3:
- Stop Process = SIGSTOP (pause signal, let's you continue later with SIGCONT, does not kill process)
- End Process = SIGTERM (termination signal, the right way, the application can intercept this signal and intiate shutdown tasks such as temp file cleanup)
- Kill Process = SIGKILL (kill signal, extreme, only use if SIGTERM doesn't work, won't intiate shutdown tasks)
See this question on Quora about SIGINT, SIGTERM, SIGKILL and SIGSTOP signals for a good explanation on all of the kill/quit/shutdown signals and their differences.