I know of one interrupt, i.e Ctrl+C which can be invoked by user in terminal.(can it be invoked elsewhere?)
Are there any other interrupts that can also be invoked by user?
I know of one interrupt, i.e Ctrl+C which can be invoked by user in terminal.(can it be invoked elsewhere?)
Are there any other interrupts that can also be invoked by user?
As far as I know, the only signals that have a default keyboard shortcut in the shell are
SIGINT
(Ctrl + C) to stop a process andSIGTSTP
(Ctrl + Z) to pause one.Apparently, as Radu Rădeanu just taught me, there is also Ctrl+\ which is mapped to
SIGQUIT
.You can find a list of all signals and what they do in
man 7 signal
:You can see the signals that are available on your system with
kill -l
:Note that there are many
SIGRTMAX
andSIGRTMIN
signals, the Linux kernel supports 32 different signals but the range of signals actually supported will depend on theglibc
implementation on your system.The
SIGQUIT
signal is similar toSIGINT
(produced by Ctrl+C), except that it's controlled by a different key — the QUIT character, usually Ctrl+\ — and produces a core dump when it terminates the process, just like a program error signal. You can think of this as a program error condition "detected" by the user.So, Ctrl+\ (Ctrl + Backslash) may be what you want.
Reference: Termination Signals.