CPU Benchmarking With sysbench
Run a prime-number workload and report events per second.
01Command
$ sysbench cpu --cpu-max-prime=20000 run02What it does
sysbench's CPU test computes primes and reports throughput, giving a number that is easy to compare before and after tuning, across VMs or after a cloud instance change. Its options make the workload explicit and scriptable.
03Risk
04Undo
✓No undo needed — this command does not change persistent state.
05Sources
- sysbench.1.en.html manual page (Debian bookworm)Evidence: Documents sysbench CPU and other benchmark modes.
Last verified: 2026-10-13 · Category: System & Settings
06Related solutions
vmstat gives a compact one-line-per-interval view of CPU usage, swap activity, and I/O waits that top doesn't summarize as clearly.
Use free -h to see used, free, and available memory plus swap in GB/MiB instead of raw kilobytes.
lscpu prints the CPU model, socket/core/thread layout, base frequency, and supported instruction flags in a clean summary.