What is the difference between a normal `kill` and `kill -9` on Linux?
Answer
`kill <pid>` sends SIGTERM by default, asking the process to terminate and allowing it to run cleanup handlers. `kill -9 <pid>` sends SIGKILL, which the process cannot catch or ignore. SIGKILL is therefore a last resort after a graceful stop fails, because it can interrupt cleanup and leave external state unfinished.
Strong answer includes
- default kill sends SIGTERM
- SIGKILL cannot be handled by the target process
- uses force only after graceful termination fails
Practical example
If a local test service hangs, first stop it through `systemctl stop` or `kill <pid>` and wait briefly. Use `kill -9` only when the process remains stuck and the consequences are understood.