Terminate Processes by Name with pkill
Use pkill to send a termination signal to every process whose name matches a pattern — no PID lookup needed.
01Command
$ pkill firefox02What it does
pkill walks the process table and sends a signal to each process whose name matches the pattern; the default is SIGTERM, a graceful request to exit. You can name a different signal either way: pkill -TERM firefox is the graceful form, while pkill -KILL firefox (or pkill -9 firefox) sends SIGKILL, which cannot be caught or ignored. You can also narrow the match with -u <user> to only the processes of one user.
03Risk
04Undo
✓No undo needed — this command does not change persistent state.
05Sources
- pgrep, pkill, pidwait - look up, signal, or wait for processes based on name and other attributesEvidence: "pkill ... will send the default signal (SIGTERM) to each process instead of listing them on stdout." The page also documents the -signal and -l/--list-signals options.
- Ubuntu Manpage: pgrep, pkill, pidwait - look up, signal, or wait for processesEvidence: "pkill ... will send the default signal (SIGTERM) to each process instead of listing them on stdout."
Last verified: 2026-09-19 · Category: System & Settings
06Related solutions
Refresh the package index from all configured repositories, then install newer versions of every upgradable package.
Find every occurrence of a pattern across all files in a tree, printed as file:line:number matches.
Unpack a gzipped tarball into the current directory while printing each file as it is extracted.