What is a Process?
Key Characteristics of a Process
- PID (Process ID) → A unique number assigned to every process. Example:
1234. - Parent/Child → Processes are created by other processes. The original one is
init(PID 1, usuallysystemd). - Resources → Each process uses CPU, memory, and I/O.
- State → A process can be running, sleeping (waiting), stopped, or terminated.
Examples of Processes
- When you open Firefox → a process is created (actually multiple).
- When you run
lsin the terminal → it becomes a short-lived process. - Background services (like networking, logging) → run as processes.
Viewing Processes
ps→ snapshot of active processes.
ps aux
top→ live view of running processes.
top
htop(if installed) → interactive process viewer.
Summary
- A process = a running program.
- Identified by PID.
- Can be managed (started, stopped, killed, put in background/foreground).
- Processes are the building blocks of the Linux system — from desktop apps to hidden system services.