Linux – Artificially burden the CPU

benchmarkcpu-usagelinux

I'm looking for a command line application that will artificially burden the CPU. It needs to be better than just a busy loop. We're testing how the system holds up under heat stress and the CPU needs to generate as much heat as possible.

Best Answer

I've had good luck with:

dd if=/dev/urandom of=/dev/null bs=1024

It keeps a single thread at 100% CPU. Run multiple times to keep more cores busy. Nice it if you want to.