You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# cd phoronix-test-suite
# FORCE_TIMES_TO_RUN=1 ./phoronix-test-suite benchmark run pgbench
NOTE: When running the benchmark, you will be prompted for params to pgbench. Input in this order - 2,2,1,n (these don't matter as we will edit the script for our purpose below)
Modify the pgbench script located at /var/lib/phoronix-test-suite/installed-tests/pts/pgbench-1.14.0/pgbench
// Original default line to be changed
pg_/bin/pgbench --protocol=prepared -j $NUM_CPU_CORES $@ -n -T 45 -r pgbench >>$LOG_FILE 2>&1
// Edited line we need for our run
pg_/bin/pgbench --protocol=prepared -j $NUM_CPU_CORES -s 100 -c $NUM_CPU_CORES -N -n -T 120 -r pgbench >>$LOG_FILE 2>&1
Paste the wrapper script to run the test easily
# cd phoronix-test-suite
# cat run.sh
#!/bin/bash
if [ $# -ne 1 ];
then
./phoronix-test-suite benchmark run pgbench
else
FORCE_TIMES_TO_RUN=$1 ./phoronix-test-suite benchmark run pgbench
fi
Set the governor to perf
# echo performance | tee /sys/devices/system/cpu/cpu*/cpufreq/scaling_governor
Run the benchmark
// To benchmark, run the wrapper script without args
# ./run.sh
// To run it only n number of times, invoke it with the number of runs
# ./run.sh 1