~3 min read • Updated Jul 18, 2025
1. What Is a Process in Linux?
Every process has a unique PID (Process ID). The very first process at boot is usually init with PID 1. Processes may create child processes, forming a parent-child hierarchy. The Linux kernel maintains process information such as memory usage, CPU state, and user ownership.
2. Viewing Processes with ps
ps # Attached to current terminal
ps x # User-owned processes, including daemons
ps aux # All system processes with full details
Key Columns:
- PID — Process ID
- TTY — Associated terminal
- STAT — Process state (S = sleeping, R = running, Z = zombie)
- %CPU / %MEM — Resource usage
3. Live Monitoring with top
topDisplays real-time process data, sorted by CPU usage. Summary includes:
- System uptime and load average
- Number of tasks (running, sleeping, zombie)
- CPU and memory usage breakdown
Press h for help, q to quit.
4. Managing Processes Interactively
xlogo & # Run process in background
fg %1 # Bring job 1 to foreground
Ctrl+Z # Suspend foreground process
bg %1 # Resume job 1 in background
jobs # List background jobs
5. Sending Signals with kill and killall
kill 28401 # Send SIGTERM to PID
kill -9 28401 # Force kill with SIGKILL
killall xlogo # Kill all processes named xlogo
Common Signals:
- SIGINT (2): Interrupt
- SIGTERM (15): Graceful termination
- SIGKILL (9): Immediate force termination
- SIGSTOP / SIGCONT: Pause / Continue
6. System Shutdown Commands
shutdown -r now # Reboot immediately
poweroff # Power down system
reboot # Restart system
Proper shutdown prevents data loss and ensures filesystem integrity.
7. Advanced Monitoring Tools
| Command | Description |
|---|---|
pstree | Visual tree of process hierarchy |
vmstat 5 | Updates system stats every 5 seconds |
tload | Text graph of system load |
xload | Graphical CPU load monitor |
Conclusion
Linux provides comprehensive tools to monitor and manage processes. From listing with ps and top to controlling jobs and sending signals via kill, users can fine-tune system performance and troubleshoot efficiently. Understanding process control boosts your confidence and skill as a Linux power user.
Written & researched by Dr. Shahin Siami