send SIGTERM with command line shortcut
No, SIGTERM
cannot be sent from the command line, as noted at: https://superuser.com/a/343611/199930.
See also: https://unix.stackexchange.com/q/362559/43390
It's not entirely true that you can't send SIGTERM
from the command line. You can't send it from a keyboard shortcut, but you can send it from the command line.
Based on the man-page for kill, you are able to send a SIGTERM
to any process. You would accomplish this by finding your process in the process table (type ps
) and then type kill -15 [pid]
.
Here is a list of the keyboard shortcuts that you can use in a terminal to handle processes:
- Ctrl+C sends
SIGINT
which asks to interrupt a program but can be caught or ignored. - Ctrl+Z sends
SIGTSTP
which asks to pause a program but can be caught or ignored. This process can be resumed later. - Ctrl+\ sends
SIGQUIT
which is the same asSIGINT
except it also produces a core dump.
Source 1 and Source 2