mirror of
https://github.com/dolthub/dolt.git
synced 2026-01-06 08:50:04 -06:00
updated sysbench, tpcc utilities
This commit is contained in:
@@ -2,9 +2,15 @@
|
||||
set -e
|
||||
set -o pipefail
|
||||
|
||||
|
||||
HOST="127.0.0.1"
|
||||
PORT=3316
|
||||
DBNAME="tpcc_test"
|
||||
USER="root"
|
||||
PASS="toor"
|
||||
|
||||
SYSBENCH_TEST="oltp_point_select"
|
||||
WORKING_DIR=`mktemp -d`
|
||||
PPROF=0
|
||||
|
||||
# parse options
|
||||
# superuser.com/questions/186272/
|
||||
while test $# -gt 0
|
||||
@@ -27,28 +33,28 @@ pushd sysbench-lua-scripts
|
||||
|
||||
|
||||
sysbench \
|
||||
--mysql-host="127.0.0.1" \
|
||||
--mysql-user="root" \
|
||||
--mysql-password="toor" \
|
||||
--mysql-port=3316 \
|
||||
--mysql-host="$HOST" \
|
||||
--mysql-user="$USER" \
|
||||
--mysql-password="$PASS" \
|
||||
--mysql-port="$PORT" \
|
||||
--db-ps-mode=disable \
|
||||
"$SYSBENCH_TEST" cleanup
|
||||
|
||||
sysbench \
|
||||
--mysql-host="127.0.0.1" \
|
||||
--mysql-user="root" \
|
||||
--mysql-password="toor" \
|
||||
--mysql-port=3316 \
|
||||
--mysql-host="$HOST" \
|
||||
--mysql-user="$USER" \
|
||||
--mysql-password="$PASS" \
|
||||
--mysql-port="$PORT" \
|
||||
"$SYSBENCH_TEST" prepare
|
||||
|
||||
# run benchmark
|
||||
echo "benchmark $SYSBENCH_TEST starting at $WORKING_DIR"
|
||||
|
||||
sysbench \
|
||||
--mysql-host="127.0.0.1" \
|
||||
--mysql-user="root" \
|
||||
--mysql-password="toor" \
|
||||
--mysql-port=3316 \
|
||||
--mysql-host="$HOST" \
|
||||
--mysql-user="$USER" \
|
||||
--mysql-password="$PASS" \
|
||||
--mysql-port="$PORT" \
|
||||
--db-ps-mode=disable \
|
||||
--rand-type="uniform" \
|
||||
"$SYSBENCH_TEST" run
|
||||
|
||||
64
go/performance/scripts/mysql_tpcc.sh
Executable file
64
go/performance/scripts/mysql_tpcc.sh
Executable file
@@ -0,0 +1,64 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
set -o pipefail
|
||||
|
||||
HOST="127.0.0.1"
|
||||
PORT=3316
|
||||
DBNAME="tpcc_test"
|
||||
USER="root"
|
||||
PASS="toor"
|
||||
|
||||
if [ ! -d "./sysbench-tpcc" ]; then
|
||||
git clone https://github.com/Percona-Lab/sysbench-tpcc.git
|
||||
fi
|
||||
|
||||
pushd sysbench-tpcc
|
||||
|
||||
./tpcc.lua \
|
||||
--db-driver="mysql" \
|
||||
--mysql-db="$DBNAME" \
|
||||
--mysql-host="$HOST" \
|
||||
--mysql-port="$PORT" \
|
||||
--mysql-user="$USER" \
|
||||
--mysql-password="$PASS" \
|
||||
--time=10 \
|
||||
--report_interval=1 \
|
||||
--threads=2 \
|
||||
--tables=1 \
|
||||
--scale=1 \
|
||||
--trx_level="RR" \
|
||||
cleanup
|
||||
|
||||
|
||||
./tpcc.lua \
|
||||
--db-driver="mysql" \
|
||||
--mysql-db="$DBNAME" \
|
||||
--mysql-host="$HOST" \
|
||||
--mysql-port="$PORT" \
|
||||
--mysql-user="$USER" \
|
||||
--mysql-password="$PASS" \
|
||||
--time=10 \
|
||||
--report_interval=1 \
|
||||
--threads=2 \
|
||||
--tables=1 \
|
||||
--scale=1 \
|
||||
--trx_level="RR" \
|
||||
prepare
|
||||
|
||||
./tpcc.lua \
|
||||
--db-driver="mysql" \
|
||||
--mysql-db="$DBNAME" \
|
||||
--mysql-host="$HOST" \
|
||||
--mysql-port="$PORT" \
|
||||
--mysql-user="$USER" \
|
||||
--mysql-password="$PASS" \
|
||||
--time=10 \
|
||||
--report_interval=1 \
|
||||
--threads=2 \
|
||||
--tables=1 \
|
||||
--scale=1 \
|
||||
--trx_level="RR" \
|
||||
run
|
||||
|
||||
|
||||
echo "benchmark TPC-C complete at $WORKING_DIR"
|
||||
@@ -105,12 +105,12 @@ echo "benchmark $SYSBENCH_TEST starting at $WORKING_DIR"
|
||||
|
||||
./tpcc.lua --db-driver="mysql" --mysql-db="sbtest" --mysql-host="0.0.0.0" --mysql-port="$PORT" --mysql-user="user" --mysql-password="pass" --time=10 --report_interval=1 --threads=2 --tables=1 --scale=1 --trx_level="RR" run
|
||||
|
||||
echo "benchmark TPC-C complete at $WORKING_DIR"
|
||||
echo "DOLT_DEFAULT_BIN_FORMAT='$DOLT_DEFAULT_BIN_FORMAT'"
|
||||
echo ""
|
||||
|
||||
unset DOLT_TRANSACTION_MERGE_STOMP
|
||||
unset DOLT_DEFAULT_BIN_FORMAT
|
||||
unset ENABLE_ROW_ITER_2
|
||||
unset SINGLE_THREAD_FEATURE_FLAG
|
||||
unset GOMAXPROCS
|
||||
|
||||
echo "benchmark TPC-C complete at $WORKING_DIR"
|
||||
echo "DOLT_DEFAULT_BIN_FORMAT='$DOLT_DEFAULT_BIN_FORMAT'"
|
||||
echo ""
|
||||
|
||||
Reference in New Issue
Block a user