Identify hung or runaway Linux processes and terminate them reliably using the kill command and signals. 16.11.2025 | reading time: 2 min A process that refuses to cooperate can block work and consume resources; learn how to find that process, send the right signal with `kill`, and confirm the result. Hands-on: end a hung job Start a background sleeper, inspect it, then terminate it: ```sleep 300 & echo $! ; ps -o pid,cmd -p $(echo $!) ; kill $(echo $!) ; ps -o pid,cmd -p $(echo $!) || echo "process gone"``` — the sequence shows creating a job, checking the PID, sending SIGTERM, and verifying that the process is gone. Signals that matter Use `kill` with care: `kill PID` sends SIGTERM (15) by default and asks the process to exit cleanly; if it ignores the request use `kill -9 PID` for SIGKILL to force stop, list signals with `kill -l`, and remember that only the process owner or root may send signals. Group and special usages Send a signal to an entire process group by prefixing the group id with a minus sign like `kill -TERM -1234`, target processes by name with `pkill`, and be aware that processes in uninterruptible sleep or zombies may not respond to signals; escalating to SIGKILL or reboot may be the only option. Complementary utilities Pair `kill` with investigation tools: `ps`, `top` or `htop` reveal CPU and memory usage; `pgrep` and `pidof` help find PIDs; `systemctl` can stop managed services cleanly instead of killing their processes. When kill won't help A process in state D (uninterruptible sleep) often waits for kernel I/O and ignores signals, and a zombie process needs its parent reaped rather than killing; identify the root cause before forcing termination to avoid data loss. Finish line Stopping a misbehaving process is a small but essential skill for any Linux operator; practice responsibly, learn signal semantics, and build confidence toward certifications like CompTIA Linux+ or LPIC-1 with intensive exam preparation at bitsandbytes.academy. Join Bits & Bytes Academy First class LINUX exam preparation. processes utilities troubleshooting