Linux CLI Based Stress Test

I found a neat way for stress testing my Linux machines using the CLI. Article at the end shows you how to install things but you basically install the two libraries that you need:

sudo apt update
sudo apt install stress s-tui

Once you’ve done that, you run nproc to see how many cores you have (VERY IMPORTANT)

nproc

This will simply output a number (e.g. 1, 2, 3, 4, the list goes on).

And then with two terminal windows open, you run stress on one and s-tui in the other with flags in stress to make sure things are being tested correctly and a duration. For example, if nproc shows you have 1 core (which I do in this older Raspberry Pi Zero) and I want to run the test for 30 seconds, I would run the following

stress -c 1 -t 30

and in another window, I would run:

s-tui

This would show up as the windows below which displays clock speed, utilization, and temperature!

And that’s pretty much it!

Source:

Leave a Comment

Your email address will not be published. Required fields are marked *