[root@localhost ~]$ wget https://github.com/akopytov/sysbench/archive/1.0.zip -O "sysbench-1.0.zip"
--2019-04-25 15:49:16-- https://github.com/akopytov/sysbench/archive/1.0.zip
Resolving github.com (github.com)... 13.229.188.59, 52.74.223.119, 13.250.177.223
Connecting to github.com (github.com)|13.229.188.59|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://codeload.github.com/akopytov/sysbench/zip/1.0 [following]
--2019-04-25 15:49:17-- https://codeload.github.com/akopytov/sysbench/zip/1.0
Resolving codeload.github.com (codeload.github.com)... 54.251.140.56, 13.250.162.133, 13.229.189.0
Connecting to codeload.github.com (codeload.github.com)|54.251.140.56|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [application/zip]
Saving to: ‘sysbench-1.0.zip’ [ <=> ] 2,291,660 149KB/s in 13s 2019-04-25 15:49:31 (171 KB/s) - ‘sysbench-1.0.zip’ saved [2291660] [root@localhost ~]$ unzip -q sysbench-1.0.zip
[root@localhost ~]$ cd sysbench-1.0
[root@localhost ~/sysbench-1.0]$ yum install automake libtool –y
( many more lines suppressed ) [root@localhost ~/sysbench-1.0]$ ./autogen.sh
./autogen.sh: running `libtoolize --copy --force'
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, 'config'. ( many more lines suppressed ) src/Makefile.am: installing 'config/depcomp'
parallel-tests: installing 'config/test-driver'
./autogen.sh: running `autoconf'
Libtoolized with: libtoolize (GNU libtool) 2.4.6
Automade with: automake (GNU automake) 1.13.4
Configured with: autoconf (GNU Autoconf) 2.69
[root@localhost ~/sysbench-1.0]$ ./configure
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu ( many more lines suppressed ) Concurrency Kit : bundled
CK_CFLAGS : -I$(abs_top_builddir)/third_party/concurrency_kit/include
CK_LIBS : $(abs_top_builddir)/third_party/concurrency_kit/lib/libck.a
configure flags :
=============================================================================== [root@localhost ~/sysbench-1.0]$ make
Making all in doc
make[1]: Entering directory `/root/sysbench-1.0/doc'
Making all in xsl
make[2]: Entering directory `/root/sysbench-1.0/doc/xsl' ( many more lines suppressed ) make[1]: Entering directory `/root/sysbench-1.0'
make[1]: Nothing to be done for `all-am'.
make[1]: Leaving directory `/root/sysbench-1.0'
[root@localhost ~/sysbench-1.0]$ make install
Making install in doc
make[1]: Entering directory `/root/sysbench-1.0/doc'
Making install in xsl
make[2]: Entering directory `/root/sysbench-1.0/doc/xsl'
make[3]: Entering directory `/root/sysbench-1.0/doc/xsl' ( many more lines suppressed ) make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory `/root/sysbench-1.0'
make[1]: Leaving directory `/root/sysbench-1.0'
[root@localhost ~/sysbench-1.0]$ sysbench --version
sysbench: error while loading shared libraries: libmysqlclient.so.20: cannot open shared object file: No such file or directory
[root@localhost /usr/local/mysql/lib]$ export LD_LIBRARY_PATH=/usr/local/mysql/lib
[root@localhost /usr/local/mysql/lib]$ sysbench --version
sysbench 1.0.17
[root@localhost /usr/local/mysql/lib]$ cd
[root@localhost ~]$ ls
dbdump.db sysbench-1.0 sysbench-1.0.zip
[root@localhost ~]$ cd sysbench-1.0/
[root@localhost ~/sysbench-1.0]$ mysqladmin create sbtest -uroot -p
Enter password:
[root@localhost ~/sysbench-1.0]$ sysbench ./tests/include/oltp_legacy/oltp.lua --mysql-host=localhost --mysql-port=3306 --mysql-user=root --mysql-password=mysql --oltp-test-mode=complex --oltp-tables-count=10 --oltp-table-size=100000 --threads=10 --time=120 --report-interval=10 prepare
sysbench 1.0.17 (using bundled LuaJIT 2.1.0-beta2) Creating table 'sbtest1'...
Inserting 100000 records into 'sbtest1'
Creating secondary indexes on 'sbtest1'...
Creating table 'sbtest2'...
Inserting 100000 records into 'sbtest2'
Creating secondary indexes on 'sbtest2'...
Creating table 'sbtest3'...
Inserting 100000 records into 'sbtest3'
Creating secondary indexes on 'sbtest3'...
Creating table 'sbtest4'...
Inserting 100000 records into 'sbtest4'
Creating secondary indexes on 'sbtest4'...
Creating table 'sbtest5'...
Inserting 100000 records into 'sbtest5'
Creating secondary indexes on 'sbtest5'...
Creating table 'sbtest6'...
Inserting 100000 records into 'sbtest6'
Creating secondary indexes on 'sbtest6'...
Creating table 'sbtest7'...
Inserting 100000 records into 'sbtest7'
Creating secondary indexes on 'sbtest7'...
Creating table 'sbtest8'...
Inserting 100000 records into 'sbtest8'
Creating secondary indexes on 'sbtest8'...
Creating table 'sbtest9'...
Inserting 100000 records into 'sbtest9'
Creating secondary indexes on 'sbtest9'...
Creating table 'sbtest10'...
Inserting 100000 records into 'sbtest10'
Creating secondary indexes on 'sbtest10'...
[root@localhost ~/sysbench-1.0]$ cd
[root@localhost ~]$ touch tmp.log.sysbench
[root@localhost ~]$ ls
dbdump.db sysbench-1.0 sysbench-1.0.zip tmp.log.sysbench
[root@localhost ~]$ cd sysbench-1.0/
[root@localhost ~/sysbench-1.0]$ sysbench ./tests/include/oltp_legacy/oltp.lua --mysql-host=localhost --mysql-port=3306 --mysql-user=root --mysql-password=mysql --oltp-test-mode=complex --oltp-tables-count=10 --oltp-table-size=100000 --threads=10 --time=120 --report-interval=10 run >> /root/tmp.log.sysbench
[root@localhost ~/sysbench-1.0]$ sysbench ./tests/include/oltp_legacy/oltp.lua --mysql-host=localhost --mysql-port=3306 --mysql-user=root --mysql-password=mysql cleanup
sysbench 1.0.17 (using bundled LuaJIT 2.1.0-beta2) Dropping table 'sbtest1'...
[root@localhost ~/sysbench-1.0]$ cd
[root@localhost ~]$ cat tmp.log.sysbench
WARNING: --num-threads is deprecated, use --threads instead
WARNING: --max-time is deprecated, use --time instead
sysbench 1.0.17 (using bundled LuaJIT 2.1.0-beta2) FATAL: Cannot find benchmark 'oltp': no such built-in test, file or module
sysbench 1.0.17 (using bundled LuaJIT 2.1.0-beta2) Running the test with following options:
Number of threads: 10
Report intermediate results every 10 second(s)
Initializing random number generator from current time Initializing worker threads... Threads started! [ 10s ] thds: 10 tps: 601.84 qps: 12049.64 (r/w/o: 8436.69/2408.27/1204.68) lat (ms,95%): 29.72 err/s: 0.10 reconn/s: 0.00
[ 20s ] thds: 10 tps: 710.18 qps: 14200.78 (r/w/o: 9939.40/2841.02/1420.36) lat (ms,95%): 22.69 err/s: 0.00 reconn/s: 0.00
[ 30s ] thds: 10 tps: 716.51 qps: 14335.45 (r/w/o: 10035.90/2866.53/1433.02) lat (ms,95%): 21.50 err/s: 0.00 reconn/s: 0.00
[ 40s ] thds: 10 tps: 754.00 qps: 15077.41 (r/w/o: 10554.31/3015.10/1508.00) lat (ms,95%): 20.37 err/s: 0.00 reconn/s: 0.00
[ 50s ] thds: 10 tps: 700.58 qps: 14010.19 (r/w/o: 9807.18/2801.84/1401.17) lat (ms,95%): 22.69 err/s: 0.00 reconn/s: 0.00
[ 60s ] thds: 10 tps: 719.10 qps: 14388.35 (r/w/o: 10073.03/2876.91/1438.40) lat (ms,95%): 21.89 err/s: 0.10 reconn/s: 0.00
[ 70s ] thds: 10 tps: 678.72 qps: 13573.33 (r/w/o: 9500.63/2715.27/1357.43) lat (ms,95%): 23.95 err/s: 0.10 reconn/s: 0.00
[ 80s ] thds: 10 tps: 657.61 qps: 13152.83 (r/w/o: 9206.76/2630.75/1315.32) lat (ms,95%): 25.28 err/s: 0.00 reconn/s: 0.00
[ 90s ] thds: 10 tps: 664.21 qps: 13289.77 (r/w/o: 9302.32/2659.03/1328.42) lat (ms,95%): 24.83 err/s: 0.00 reconn/s: 0.00
[ 100s ] thds: 10 tps: 732.88 qps: 14654.96 (r/w/o: 10259.69/2929.21/1466.06) lat (ms,95%): 20.74 err/s: 0.30 reconn/s: 0.00
[ 110s ] thds: 10 tps: 740.67 qps: 14814.08 (r/w/o: 10370.03/2962.60/1481.45) lat (ms,95%): 20.74 err/s: 0.10 reconn/s: 0.00
[ 120s ] thds: 10 tps: 649.06 qps: 12982.91 (r/w/o: 9088.55/2596.54/1297.82) lat (ms,95%): 26.20 err/s: 0.10 reconn/s: 0.00
SQL statistics:
queries performed:
read: 1165836
write: 333068
other: 166540
total: 1665444
transactions: 83266 (693.79 per sec.)
queries: 1665444 (13876.86 per sec.)
ignored errors: 8 (0.07 per sec.)
reconnects: 0 (0.00 per sec.) General statistics:
total time: 120.0144s
total number of events: 83266 Latency (ms):
min: 3.66
avg: 14.41
max: 118.63
95th percentile: 23.52
sum: 1199489.04 Threads fairness:
events (avg/stddev): 8326.6000/59.57
execution time (avg/stddev): 119.9489/0.01

MYSQL性能测试工具SYSBENCH的更多相关文章

  1. MySQL性能测试工具sysbench的安装和使用

    sysbench是一个开源的.模块化的.跨平台的多线程性能测试工具,可以用来进行CPU.内存.磁盘I/O.线程.数据库的性能测试.目前支持的数据库有MySQL.Oracle和PostgreSQL.当前 ...

  2. Linux 性能测试工具 sysbench 的安装与简单使用

    文章目录 Linux 性能测试工具 sysbench 的安装与简单使用        一 背景        二 实验环境            2.1 操作系统            2.2 其他配 ...

  3. MySQL性能测试工具之mysqlslap

    MySQL性能测试工具之mysqlslap [日期:2014-10-05] 来源:Linux社区  作者:tongcheng [字体:大 中 小]   --转自Linux社区:http://www.l ...

  4. Mysql多线程性能测试工具sysbench 安装、使用和测试

    From:http://www.cnblogs.com/zhoujinyi/archive/2013/04/19/3029134.html 摘要:      sysbench是一个开源的.模块化的.跨 ...

  5. 开源多线程性能测试工具-sysbench

    导读 sysbench是一款开源的多线程性能测试工具,可以执行CPU/内存/线程/IO/数据库等方面的性能测试.数据库目前支持MySQL/Oracle/PostgreSQL.本文主要演示Mysql测试 ...

  6. MySQL 常用工具sysbench/fio/tpcc等测试

    为什么要压力测试采购新设备,评估新设备性能开发新项目,评估数据库容量新系统上线前,预估/模拟数据库负载更换数据库版本,评估性能变化 关注指标  CPU %wait,%user,%sys 内存 只内存读 ...

  7. MySQL基准测试工具--sysbench

    我们需要知道的是sysbench并不是一个压力测试工具,是一个基准测试工具.linux自带的版本比较低,我们需要自己安装sysbench. [root@test2 ~]# sysbench --ver ...

  8. 安装性能测试工具:sysbench和使用apache的ab

    一.软件的用途,它主要包括以下几种方式的测试:1.cpu性能2.磁盘io性能3.调度程序性能4.内存分配及传输速度5.POSIX线程性能6.数据库性能(OLTP基准测试) 这个软件为什么找不到官网呢? ...

  9. Linux系统性能测试工具sysbench

    1.CPU性能测试 sysbench --test=cpu --cpu-max-prime= --num-threads= run 2.内存性能测试 sysbench --test=memory -- ...

随机推荐

  1. myeclipse开发javaweb难点总结

    修改项目部署名:右键项目首选项—搜web 创建servlet:先在src下面建包,com.yhh.servlet,然后建新servlet,第二页改url为别名,这种方法xml会自动配置好 配置哪个服务 ...

  2. How to display `top` results sorted by memory usage in real time?

    If you're using the top that comes with Ubuntu (top -v = procps-ng version 3.3.10), then you can use ...

  3. python3中用django下载文件,中文名乱码怎么办?

    前段时间被某个前端小可爱鄙视了一下,说我博客都一年不更新了,我不服,明明还有俩月才到一年呢.不过说是这么说,还是要更新一下的. 以上都是借口,下面开始正文.     我公司的某个内部系统,用djang ...

  4. 推荐一款健康App 多喝水,引领全民时尚喝水生活习惯

    推荐一款健康App 多喝水,引领全民时尚喝水生活习惯 1 介绍 多喝水,一款鼓励大众喝水的APP.我们倡导大众健康生活,培养人们爱喝水的习惯,让每一次喝水,都能产生价值,让人们在喝水的同时,可享受赚钱 ...

  5. LeetCode 485:连续最大1的个数 Max Consecutive Ones(python java)

    公众号:爱写bug 给定一个二进制数组, 计算其中最大连续1的个数. Given a binary array, find the maximum number of consecutive 1s i ...

  6. nohup 启动后台应用

    nohup java -Xmx1024M -Xms1024M -jar app.jar --logging.level=warn --logging.path=/var/log/app--server ...

  7. [转帖]【译】RAID的概念和RAID对于SQL性能的影响

    [译]RAID的概念和RAID对于SQL性能的影响 https://www.cnblogs.com/VicLiu/p/11479427.html 简介 我们都听说过RAID,也经常作为SQL DBA. ...

  8. springBoot获取@NotBlank,@NotNull注解的message信息

    概述 springBoot后台验证接收的参数是否不合法时,会抛出一个BlndException异常,获取message的自定义信息并返回 验证 UserEntity类 @Data @Entity @T ...

  9. ​ Markdown

    Cygwin ​ Markdown是一种可以使用普通文本编辑器编写的标记语言,通过简单的标记语法,它可以使普通文本内容具有一定的格式. ​ Markdown具有一系列衍生版本,用于扩展Markdown ...

  10. Golang fmt Printf 格式化参数手册/详解/说明

    fmt 包实现了格式化I/O函数,类似于C的 printf 和 scanf. 格式“占位符”衍生自C,但比C更简单. fmt 包的官方文档对Printing和Scanning有很详细的说明.这里就直接 ...