Scroll to navigation

SYSBENCH(1) Benchmark tool for database systems SYSBENCH(1)

NAME

sysbench - multi-threaded benchmark tool for database systems

SYNOPSIS

sysbench [common-options] --test=name [test-options] <command>
Commands: prepare run cleanup help version

DESCRIPTION

SysBench is a modular, cross-platform and multi-threaded benchmark tool for evaluating OS parameters that are important for a system running a database under intensive load.

The idea of this benchmark suite is to quickly get an impression about system performance without setting up complex database benchmarks or even without installing a database at all.

The design is very simple. SysBench runs a specified number of threads and they all execute requests in parallel. The actual workload produced by requests depends on the specified test mode. You can limit either the total number of requests or the total time for the benchmark, or both.

Compiled-in database drivers:

  • mysql - MySQL driver
  • pgsql - PostgreSQL driver

Compiled-in tests:

  • fileio - File I/O test
  • cpu - CPU performance test
  • memory - Memory functions speed test
  • threads - Threads subsystem performance test
  • mutex - Mutex performance test

Available test modes are implemented by compiled-in modules, and SysBench was designed to make adding new test modes an easy task. Each test mode may have additional (or workload-specific) options.

GENERAL OPTIONS

number of threads to use [1]
limit for total number of requests [10000]
limit for total execution time in seconds [0]
amount of time to wait after --max-time before forcing shutdown [off]
size of stack per thread [64K]
target transaction rate (tps) [0]
periodically report intermediate statistics with a specified interval in seconds. 0 disables intermediate reports [0]
dump full statistics and reset all counters at specified points in time. The argument is a list of comma-separated values representing the amount of time in seconds elapsed from start of test when report checkpoint(s) must be performed. Report checkpoints are off by default. []
test to run
print more debugging info [off]
perform validation checks where possible [off]
print help and exit
print version and exit [off]
random numbers distribution {uniform,gaussian,special,pareto} [special]
number of iterations used for numbers generation [12]
percentage of values to be treated as 'special' (for special distribution) [1]
percentage of 'special' values to use (for special distribution) [75]
seed for random number generator, ignored when 0 [0]
parameter h for pareto distribution [0.2]
File containing command line options

LOG OPTIONS

verbosity level {5 - debug, 0 - only critical messages} [3]
percentile rank of query response times to count. Use the special value of 0 to disable percentile statistics. [95]

GENERAL DATABASE OPTIONS

specifies database driver to use ('help' to get list of available drivers) --db-ps-mode=STRING prepared statements usage mode {auto, disable} [auto] --db-debug=[on|off] print database-specific debug information [off]

MYSQL OPTIONS

MySQL server host [localhost]
MySQL server port [3306]
MySQL socket
MySQL user [sbtest]
MySQL password []
MySQL database name [sbtest]
storage engine to use for the test table {myisam,innodb,bdb,heap,ndbcluster,federated} [innodb]
whether storage engine used is transactional or not {yes,no,auto} [auto]
use SSL connections, if available in the client library [off] --mysql-compression=[on|off] use compression, if available in the client library [off]
max-rows parameter for MyISAM tables [1000000]
dump all client library calls [off] --mysql-ignore-errors=[LIST,...]list of errors to ignore, or "all" [1213,1020,1205]
Dry run, pretent that all MySQL client API calls are successful without executing them [off]

PGSQL OPTIONS

PostgreSQL server host [localhost]
PostgreSQL server port [5432]
PostgreSQL user [sbtest] --pgsql-password=STRING PostgreSQL password []
PostgreSQL database name [sbtest]

FILEIO OPTIONS

number of files to create [128]
block size to use in all IO operations [16384]
total size of files to create [2G]
test mode {seqwr, seqrewr, seqrd, rndrd, rndwr, rndrw}
file operations mode {sync,async,mmap} [sync]
number of asynchronous operatons to queue per thread [128]
additional flags to use on opening files {sync,dsync,direct} []
do fsync() after this number of requests (0 - don't use fsync()) [100]
do fsync() after each write operation [off]
do fsync() at the end of test [on]
which method to use for synchronization {fsync, fdatasync} [fsync]
merge at most this number of IO requests if possible (0 - don't merge) [0]
reads/writes ratio for combined test [1.5]

CPU OPTIONS

upper limit for primes generator [10000]

MEMORY OPTIONS

size of memory block for test [1K]
total size of data to transfer [100G]
memory access scope {global,local} [global]
allocate memory from HugeTLB pool [off]
type of memory operations {read, write, none} [write] --memory-access-mode=STRING memory access mode {seq,rnd} [seq]

THREAD OPTIONS

number of yields to do per request [1000]
number of locks per thread [8]

MUTEX OPTIONS

total size of mutex array [4096]
number of mutex locks to do per thread [50000]
number of empty loops to do inside mutex lock [10000]

SEE ALSO

Upstream provided html-formatted manual, describing the features of sysbench: /usr/share/doc/sysbench/manual.html

27 May 2017