LINUX / A CONCEPT NOTE
Processes & Signals
how programs live and die
Overview · mechanism
pitfall · examples
01 / THE SHORT VERSION
The idea in a few sentences.
A process is a running instance of a program with its own PID, memory space, and file descriptors. Signals are asynchronous notifications sent to processes to trigger actions like termination.
02 / FOLLOW THE MECHANISM
How a process responds to signals
Trigger
user or system sends a signal (e.g., kill -15 PID).
Signal Dispatch
kernel halts process execution and transfers control to the signal handler.
Handler Action
process either intercepts the signal (SIGTERM) to clean up, or gets terminated instantly by kernel (SIGKILL).
Exit status
parent process reaps the exit code using wait() to avoid leaving a zombie process.
04 / COMMAND NOTES
Read the command, then the result.
Inspect the flags and arguments before trying an example. Snippets can need local setup, replacement values, or resources in your own environment.
find the process IDs (PIDs) of running apps
ps aux | grep nginxforce kill a process instantly
kill -9 PID05 / CHECK YOURSELF
Could you explain Processes & Signals to a teammate?
Try it out loud in two sentences: what it is, and the one detail that changes the picture. If you stall, the gap is the part to reread.
Up next in Linux & systemsFile Permissionsrwx and who you are