Linux VPS

VPS slow with high I/O wait: how to find and fix disk bottlenecks

Is your VPS slow while CPU looks idle? High I/O wait means processes are waiting on the disk. Learn how to measure it with top and iostat, find the culprit and fix it.

AdvancedLinux VPS2 min read

A VPS with high I/O wait feels slow and unresponsive even though CPU usage seems low. The wa value in top shows the share of time the CPU sits idle waiting for disk reads and writes. When it stays high, something is hammering the disk, or the VPS is swapping because it is short of memory.

Before you start

  • Root SSH access to the VPS.
  • Install the tools if missing: sysstat (for iostat) and iotop.

Measure I/O wait

  1. Run top and look at the %Cpu(s) line. A wa value regularly above 10–20% indicates a disk bottleneck.
  2. Run iostat -x 2 5 and check %util and await for each disk. Utilisation near 100% with long await times confirms it.
  3. Run vmstat 2 5. Non-zero si/so columns mean the system is swapping.

Find the process causing it

iotop -oPa

This lists processes actually reading or writing, with totals. Typical culprits are MySQL/MariaDB, backup jobs, log writers, mail queues and malware scanners.

Fix common causes

  • Swapping: the real problem is memory. Reduce memory use (PHP-FPM children, MySQL buffers) or add RAM. See out of memory issues.
  • MySQL: increase innodb_buffer_pool_size so data is served from RAM, and fix slow queries without indexes.
  • Backups during peak hours: reschedule them at night and run them with ionice -c3 nice -n19.
  • Huge or chatty logs: lower log verbosity and set up logrotate.
  • A big mail queue: clear spam from the queue and fix the source; see mail queue commands.
  • Disk nearly full: filesystems slow down near capacity; see no space left on device.

Note: On a virtual server the disk is shared hardware. If iowait is high but no process on your VPS is busy, contact your provider with iostat output so they can check the host.

FAQ

What is a normal I/O wait?

Under a few percent most of the time, with short spikes during backups.

Does NVMe storage stop I/O wait?

It greatly reduces it, but swapping or a runaway process can still saturate any disk.

Is high iowait the same as high load?

Processes waiting on disk count in the load average, so high iowait raises load even with idle CPU.

Next steps

Was this guide helpful?

Still stuck?

Ask MdmHost AI for a quick answer, or open a ticket and our team will take a look. We are here 24/7.