atop — Full-system resource monitor
Linux / Service and process management / atop.html
Records CPU, memory, disk and network usage together and can replay past intervals.
Basic Information
| Command Name | atop |
|---|---|
| One-line Introduction | Records CPU, memory, disk and network usage together and can replay past intervals. |
| Provided by | atop project (packaged by distributions) |
| Official Documentation | https://man7.org/linux/man-pages/man1/atop.1.html |
| Supported Operating Systems | Linux |
| Installation Status | Package required (apt install atop) |
| Category | Linux service and process management (tags: Process and resource management (tags: monitoring, performance, resource, process)) |
What is this command?
atop shows per-process usage together with system-wide counters in one screen.
Its interval log lets you replay the exact state of the machine around an incident.
What problems does it solve?
- Find which process caused a short load spike.
- Decide whether memory, disk or network is the bottleneck.
- Replay the machine state at the moment of an incident.
- Record at intervals overnight and review the trend in the morning.
Key features
Live view
The default run refreshes system counters and top processes at a fixed interval.
- When to use: When you need a quick current picture
- What you get: CPU, memory, disk and network summary
- Limitations: Short spikes may fall between intervals
Interval logging and replay
Write samples to a file at a fixed interval and replay them with -r.
- When to use: When investigating after an incident
- What you get: Per-interval counters and process list
- Limitations: Log files grow, so a retention policy is needed
Switching process views
Interactive keys change sorting and open detailed per-process views.
- When to use: When drilling into one process
- What you get: Sorted process list with detail
- Limitations: Requires learning the key bindings
Installation and usage
Check whether it is installed
atop -V
apt install atop # Debian/Ubuntu dnf install atop # Fedora/RHEL
Real-world examples
Live monitoring
Refresh every 5 seconds.
# Refresh every 5 seconds
atop 5
Interval logging
Log one day of samples every 60 seconds.
# Sample every 60 seconds into a log file
atop -w /var/log/atop.daily 60
Replaying a log
Replay a recorded file from the start.
# Replay the recorded samples
atop -r /var/log/atop.daily