Skip to content
Search Oracle Linux

    Browse this documentation

    The performance troubleshooting toolbox: vmstat/iostat/pidstat outputs and how to read them (OL 10.2)

    The four fundamentals of performance troubleshooting: the whole machine (vmstat), disks (iostat), processes (pidstat), load (uptime). Each comes with a measured idle baseline — knowing “what normal looks like” is what lets you recognize “not normal”.

    Terminal window
    rpm -q procps-ng sysstat
    # procps-ng present (vmstat/ps/top available)
    # sysstat absent → dnf install -y sysstat (iostat/mpstat/pidstat/sar)

    vmstat: a 10-second whole-machine portrait

    Section titled “vmstat: a 10-second whole-machine portrait”
    Terminal window
    vmstat 1 2 # only the second line is a valid sample (the first is the average since boot)
    r b swpd free buff cache si so bi bo in cs us sy id wa
    0 0 44648 295588 2112 1028156 0 0 0 0 177 146 0 0 100 0

    Reading it: r the run queue (persistently > core count = CPU-starved), si/so paging (non-zero = memory pressure), wa IO wait (>20% = storage bottleneck), id idle. Measured idle baseline: id=100, si/so=0.

    Terminal window
    iostat -x 1 2 | grep -A3 "Device.*await" | tail -3
    Device r/s rkB/s w/s wkB/s w_await aqu-sz %util
    dm-0 0.00 0.00 540.00 6934.50 0.35 0.00 0.80

    Reading it: await (the average request wait, ms) — under 1ms is normal for SSDs, under 10ms for spinning disks, and a sustained >50ms means storage overload; %util (device busyness) sitting at ≈100% means saturation. Measured idle baseline: w_await 0.35ms, %util 0.80.

    Terminal window
    pidstat 1 1 # the CPU view (-r memory / -d IO / -w context switches)

    Measured: an idle machine’s PID table is all zeros — a normal baseline. This is the tool for “who is eating CPU/memory/IO”, cross-checked with top -b -n1.

    uptime: the three load numbers against core count

    Section titled “uptime: the three load numbers against core count”
    Terminal window
    uptime
    # load average: 0.00, 0.00, 0.00

    Load = runnable + uninterruptible tasks. The rule of thumb: load persistently > core count (nproc) → queuing; watch the trend difference between 1min and 15min (a sudden spike vs a long-term high).

    The troubleshooting opening move (the combination)

    Section titled “The troubleshooting opening move (the combination)”
    Terminal window
    uptime && vmstat 1 3 # characterize the whole machine first
    iostat -x 1 2 # wa high → look at disks
    pidstat 1 2 or pidstat -r 1 2 # locate the process
    journalctl -k --since "10 min ago" # the kernel side (OOM/throttle)
    • Measured: the package boundary and the vmstat/iostat/pidstat/uptime idle-baseline outputs (E3);
    • Not measured: anomaly samples under real load (to be injected later under stress) and sar’s historical collection (the sysstat service);
    • Sources: vmstat(8), iostat(1), pidstat(1), OL10 performance documentation.