mysql基准测试-sysbench

来源:互联网 发布:mysql 按月份查询 编辑:程序博客网 时间:2024/05/16 00:27

此次的基准测试,通过sysbench工具完成,主要对比组也是通过去租参数去完成,并对照结果。


对比参数

innodb_flush_log_at_trx_commit

sync-binlog


1组innodb_flush_log_at_trx_commit = 2sync-binlog = 12组innodb_flush_log_at_trx_commit = 2sync-binlog = 0


sysbench参数:

1组oltp_tables_count=15oltp-table-size=10000000num-threads=128oltp-read-only=offrand-type=uniformmax-time=1500percentile=992组oltp_tables_count=15oltp-table-size=10000000num-threads=128oltp-read-only=offrand-type=uniformmax-time=1500percentile=99



测试结果:

1组read                       31575810write9021660other4510830total45108300transactions2255415 (1503.56 per sec.)deadlocks0      (0.00 per sec.)read/write requests40597470 (27063.99 per sec.)other operations4510830 (3007.11 per sec.)response timemin7.34msavg85.12msmax8072.93ms99 percentile351.16ms2组read                      42732508write12209288other6104644total61046440transactions3052322 (2034.75 per sec.)deadlocks0      (0.00 per sec.)read/write requests54941796 (36625.46 per sec.)other operations6104644 (4069.50 per sec.)response timemin3.33msavg62.90msmax19946.42ms99 percentile204.27ms


测试结论:

通过2组对比测试,当sync-binlog为1时,mysql性能显著的下降,下降约(2034.75-1503.56)/2034.75*100%=26.11%。这个是sysbench测试的结果,tpcc-mysql测试的性能下降比这个要小很多,约10%左右。