mib文件导入mysql数据库_mysql之 sysbench1.0.3 安装与系统压力测试

本文介绍了sysbench工具的下载、安装及使用,包括CPU性能测试、内存性能测试、磁盘IO性能测试和线程、互斥锁测试。sysbench是一个强大的系统和数据库压力测试工具,适用于评估和优化MySQL等数据库及系统性能。
摘要由CSDN通过智能技术生成

针对系统和数据库压测是项目上线前必做的一项,这里使用的是最新版本的sysbench做的压测使用详解。sysbench可以做系统层面的压力测试(CPU、内存、硬盘IO、互斥锁、Thead),也可以做数据库(MySQL/Oracle/PG)层面的压力测试。安装容易,操作便捷,是压测使用的重要工具之一。

一、sysbench下载

项目地址:https://launchpad.net/sysbench下载地址:https://github.com/akopytov/sysbench/archive/1.0.3.tar.gz二、sysbench安装

[root@DB_TEST tools]# tar -xzvf sysbench-1.0.3.tar.gz

[root@DB_TEST tools]# cd sysbench-1.0.3

[root@DB_TEST sysbench-1.0.3]# ./autogen.sh

[root@DB_TEST sysbench-1.0.3]#./configure  --prefix=/usr/local/sysbench --with-mysql

[root@DB_TEST sysbench-1.0.3]# make

[root@DB_TEST sysbench-1.0.3]# make install

[root@DB_TEST sysbench-1.0.3]#  cp -rp /usr/local/sysbench/bin/sysbench  /usr/bin/

[root@DB_TEST sysbench-1.0.3]# /usr/local/sysbench/bin/sysbench --help

点击(此处)折叠或打开

[root@BJ-133-22 sysbench-1.0.3]# /usr/local/sysbench/bin/sysbench --help

Usage:

sysbench [options]... [testname] [command]

Commands implemented by most tests: prepare run cleanup help

General options:

--threads=N number of threads to use [1]

--events=N limit for total number of events [0]

--time=N limit for total execution time in seconds [10]

--forced-shutdown=STRING number of seconds to wait after the --time limit before forcing shutdown, or 'off' to disable [off]

--thread-stack-size=SIZE size of stack per thread [64K]

--rate=N average transactions rate. 0 for unlimited rate [0]

--report-interval=N periodically report intermediate statistics with a specified interval in seconds. 0 disables intermediate reports [0]

--report-checkpoints=[LIST,...] 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. []

--debug[=on|off] print more debugging info [off]

--validate[=on|off] perform validation checks where possible [off]

--help[=on|off] print help and exit [off]

--version[=on|off] print version and exit [off]

--config-file=FILENAME File containing command line options

--tx-rate=N deprecated alias for --rate [0]

--max-requests=N deprecated alias for --events [0]

--max-time=N deprecated alias for --time [0]

--num-threads=N deprecated alias for --threads [1]

Pseudo-Random Numbers Generator options:

--rand-type=STRING random numbers distribution {uniform,gaussian,special,pareto} [special]

--rand-spec-iter=N number of iterations used for numbers generation [12]

--rand-spec-pct=N percentage of values to be treated as 'special' (for special distribution) [1]

--rand-spec-res=N percentage of 'special' values to use (for special distribution) [75]

--rand-seed=N seed for random number generator. When 0, the current time is used as a RNG seed. [0]

--rand-pareto-h=N parameter h for pareto distibution [0.2]

Log options:

--verbosity=N verbosity level {5 - debug, 0 - only critical messages} [3]

--percentile=N percentile to calculate in latency statistics (1-100). Use the special value of 0 to disable percentile calculations [95]

--histogram[=on|off] print latency histogram in report [off]

General database options:

--db-driver=STRING 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 info

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值