Benchmarking

Benchmarking is the process of testing and measuring the performance of various hardware components, such as the CPU, GPU, memory, and disk, as well as software applications running on the system. The purpose of benchmarking is to determine how well a system or component performs under specific workloads and compare the results with other systems or components.

When it comes to performance testing on Linux, there are a few popular tools that stand out from the crowd. Whether you’re trying to benchmark your system’s performance or stress test your CPU to see how it handles heavy workloads, these tools will give you the data you need.

Geekbench

Geekbench is a well-known benchmarking tool that’s available on Linux, as well as macOS and Windows. It’s easy to use and provides a detailed report of your system’s performance. To install Geekbench on Ubuntu, simply open a terminal and run the following commands

sudo apt update
sudo apt install geekbench

Once installed, you can run Geekbench by typing “geekbench5” in your terminal. This will launch the Geekbench 5 benchmarking tool, which will test your system’s CPU and memory performance. Once the benchmark is complete, you’ll get a report with detailed information about your system’s performance, including a single-core score, a multi-core score, and more.

$ geekbench5
Geekbench 5.4.1 Tryout : https://www.geekbench.com/
Benchmark Configuration:
  - Benchmark Mode:      Tryout
  - CPU Benchmark:      Enabled
  - GPU Benchmark:      Disabled
  - Compute Benchmark:  Disabled
  - OpenCL:             1.2
  - Metal:              0.0
  - CUDA:               0.0
  - Platform Notes:     

[...]

Phoronix Test Suite

Experience the power of Phoronix Test Suite – the go-to benchmarking tool designed exclusively for Linux. It’s open source and supports a wide range of tests, including CPU, memory, and disk performance. To install Phoronix Test Suite on Ubuntu, open a terminal and run the following commands

sudo apt update
sudo apt install phoronix-test-suite

After launching the tool, you can choose from a range of available tests to run on your system.

$ phoronix-test-suite
Phoronix Test Suite v10.2.2
  https://www.phoronix-test-suite.com/

Usage: phoronix-test-suite [OPTIONS] [SUB-COMMAND [OPTIONS]]

phoronix-test-suite help                    - Help on the available commands
phoronix-test-suite install                 - Install tests and suites
phoronix-test-suite run                     - Run a test/suite
phoronix-test-suite gui                     - Launch the GTK GUI interface
phoronix-test-suite list-available-tests    - List all available tests
phoronix-test-suite list-installed-tests    - List all installed tests
phoronix-test-suite dump-xml                - Dump the test results in XML format
phoronix-test-suite compare-results         - Compare test results
phoronix-test-suite remove                  - Remove a test/suite
[...]

Sysbench

Sysbench is a versatile benchmarking tool that’s designed for Linux systems. It can test everything from CPU performance to database performance, and it’s easy to use.

sudo apt update
sudo apt install sysbench

Once installed, you can run Sysbench by typing “sysbench” in your terminal.

$ sysbench --version
sysbench 1.0.17

$ sysbench cpu run
sysbench 1.0.17 (using system LuaJIT 2.1.0-beta3)

Running the test with following options:
Number of threads: 1
Initializing random number generator from current time

Prime numbers limit: 10000

Initializing worker threads...

Threads started!

CPU speed:
    events per second:   239.97

General statistics:
    total time:                          10.0011s
    total number of events:              2401

Latency (ms):
         min:                                  4.00
         avg:                                  4.17
         max:                                 12.36
         95th percentile:                      4.00
         sum:                              10004.17

Threads fairness:
    events (avg/stddev):           2401.0000/0.00
    execution time (avg/stddev):   10.0012/0.00

Stress-ng

Stress-ng is a CPU stress testing tool that’s designed to push your system to its limits. It’s easy to use and provides detailed information about your system’s performance under heavy load.

sudo apt update
sudo apt install stress-ng

Run “stress-ng” in your terminal.

$ stress-ng --cpu 2 --io 2 --vm 2 --vm-bytes 128M --timeout 10s
stress-ng: info:  [9988] dispatching hogs: 2 cpu, 2 io, 2 vm
stress-ng: info:  [9988] successful run completed in 10.00s (100.00s), stressors launched: 6, stress-ng pid: 9988

Leave a Comment

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

Scroll to Top