How to See Running Processes in Linux
Use ps to inspect running processes, PIDs, users and commands.
Process inspection is the first step before stopping a program, diagnosing high CPU usage or finding which user owns a service. `ps` gives you a stable snapshot you can pipe into other tools.
Step by step
1 List processes
$ ps aux Shows processes for all users with CPU, memory, PID and command information.
2 Find one program
$ ps aux | grep nginx Filters the snapshot for a program name. Verify the result before acting on the PID.
3 Inspect one PID
$ ps -fp 12345 Shows a focused row with user, parent PID, start time and command.
4 Show a process tree
$ ps -ef --forest Displays parent/child relationships, which helps explain how a process was launched.
Tips worth knowing
- `pgrep -af name` is often cleaner than `ps aux | grep name`.
- Use top for a live view rather than repeatedly running ps.
- A PID can be reused, so re-check it before sending signals.
Frequently asked questions
How do I list all running processes?
Use `ps aux` or `ps -ef`.
How do I find a process by name?
Use `pgrep -af name` or filter `ps` output.
How do I see who owns a process?
The user column in `ps aux` shows the process owner.
The commands behind it
See what is running, find a process ID, and combine with grep to hunt down a program.
top & htopThe live dashboard: CPU, memory, load average and the processes consuming them.
killTerminate processes politely or forcibly — and understand what -9 really does.
Concepts involved: Process · PID (Process ID)
More how-to guides
See how much space is left, and find out what is using it.
Extract a .tar.gz archiveUnpack tar.gz, tar.bz2, tar.xz and zip archives from the command line.
Free a port that is already in useFind which process holds a port and stop it cleanly.
Find and replace text in filesReplace text in one file or across a whole project, safely.