To stress test and benchmark certain key aspects of it including CPU performance.
sudo apt install stress
or
sudo apt install stress-ng
NOTE: stress-ng is a newer version of stress that ships in with extra features.
Run stress or stress-ng.
sudo stress-ng --cpu 4 -v --timeout 30s
NOTE: where
top
yes > /dev/null &
NOTE: This only imposes 100% load on a single core.
To impose this against multiple cores, then run the command multiple times to exhaust all the CPU power:
yes > /dev/null & yes > /dev/null & yes > /dev/null & yes > /dev/null &
NOTE: To terminate the Linux background jobs created by the above commands:
killall yes
dd if=/dev/zero of=/dev/null
To fully utilize all the cores on your system, run the following command:
fulload() { dd if=/dev/zero of=/dev/null | dd if=/dev/zero of=/dev/null | dd if=/dev/zero of=/dev/null | dd if=/dev/zero of=/dev/null & }; fulload; read; killall dd
NOTE: The number of the above command in the function should be equal to the number of cores (for example 4 in this case).