iotop Command
Intermediate Performance & Debugging man(1)Monitor I/O usage by processes in real time
👁 10 views
📅 Updated: Mar 15, 2026
SYNTAX
iotop [OPTION]...
What Does iotop Do?
iotop monitors I/O usage per process in real time, similar to how top monitors CPU usage. It shows which processes are reading from and writing to disk, helping identify I/O-heavy processes.
iotop requires root privileges because it uses the kernel taskstats interface. It shows the actual disk read/write speed for each process, the I/O priority, and accumulated I/O.
iotop is invaluable when a system feels slow due to disk I/O. It immediately shows which process is consuming disk bandwidth.
iotop requires root privileges because it uses the kernel taskstats interface. It shows the actual disk read/write speed for each process, the I/O priority, and accumulated I/O.
iotop is invaluable when a system feels slow due to disk I/O. It immediately shows which process is consuming disk bandwidth.
Options & Flags
| Option | Description | Example |
|---|---|---|
| -o | Show only processes with I/O | sudo iotop -o |
| -b | Batch mode (non-interactive) | sudo iotop -b -n 5 |
| -n N | Number of iterations | sudo iotop -n 10 |
| -d N | Delay between updates | sudo iotop -d 2 |
| -P | Show processes instead of threads | sudo iotop -oP |
| -a | Show accumulated I/O | sudo iotop -a |
Practical Examples
#1 Show active I/O
Shows only processes actively doing I/O.
$ sudo iotop -oP
Output:
TID PRIO USER DISK READ DISK WRITE COMMAND
1234 be/4 mysql 50.00 M/s 120.00 M/s mysqld
#2 Batch mode
Shows 5 snapshots of I/O activity (for logging).
$ sudo iotop -boP -n 5#3 Accumulated I/O
Shows total I/O since iotop started.
$ sudo iotop -aoP#4 Custom interval
Updates every 3 seconds showing only active I/O.
$ sudo iotop -oP -d 3Tips & Best Practices
Use -o to filter: -o shows only processes with active I/O. Without it, every process is listed, making it hard to find the I/O hogs.
Requires root: iotop needs root because it reads kernel taskstats. Always use sudo iotop.
May not be installed: Install with: sudo apt install iotop or sudo yum install iotop.
Frequently Asked Questions
How do I find what is using the disk?
sudo iotop -oP shows processes actively reading from or writing to disk with their I/O speeds.
Why is my system slow?
Run sudo iotop -oP to check for I/O bottlenecks. High disk usage by a process explains system-wide slowness.
How is iotop different from iostat?
iotop shows per-process I/O. iostat shows per-device I/O. Use iotop to find the culprit, iostat to measure device performance.
Related Commands
More Performance & Debugging Commands
Master Linux with Professional eBooks
Curated IT eBooks covering Linux, DevOps, Cloud, and more
Browse Books →