RELATEED CONSULTING
相关咨询
选择下列产品马上在线沟通
服务时间:8:30-17:00
你可能遇到了下面的问题
关闭右侧工具栏

新闻中心

这里有您想知道的互联网营销解决方案
MySQL测试工具sysbench

1、配置 epel 源安装 sysbench

10年的东阳网站建设经验,针对设计、前端、开发、售后、文案、推广等六对一服务,响应快,48小时及时工作处理。全网整合营销推广的优势是能够根据用户设备显示端的尺寸不同,自动调整东阳建站的显示方式,使网站能够适用不同显示终端,在浏览器中调整网站的宽度,无论在任何一种浏览器上浏览网站,都能展现优雅布局与设计,从而大程度地提升浏览体验。成都创新互联公司从事“东阳网站设计”,“东阳网站推广”以来,每个客户项目都认真落实执行。

yum install -y sysbench

2、初始化数据

sysbench /usr/share/sysbench/tests/include/oltp_legacy/oltp.lua \
--MySQL-host=192.168.1.226 \
--mysql-port=3306 \
--mysql-user=root \
--mysql-password=MySQL5.7 \
--oltp-test-mode=complex \
--oltp-tables-count=10 \
--oltp-table-size=100000 \
--threads=10 \
--time=120 \
--report-interval=10 \
--db-driver=mysql prepare

3、执行测试

sysbench /usr/share/sysbench/tests/include/oltp_legacy/oltp.lua \
--mysql-host=192.168.1.226 \
--mysql-port=3306 \
--mysql-user=root \
--mysql-password=MySQL5.7 \
--oltp-test-mode=complex \
--oltp-tables-count=10 \
--oltp-table-size=100000 \
--threads=10 \
--time=120 \
--db-driver=mysql \
--report-interval=10 run 

4、清理数据

sysbench /usr/share/sysbench/tests/include/oltp_legacy/oltp.lua \
--mysql-host=192.168.1.226 \
--mysql-port=3306 \
--mysql-user=root \
--db-driver=mysql \
--oltp-tables-count=10 \
--mysql-password=MySQL5.7 cleanup

参考文档:https://www.cnblogs.com/kismetv/p/7615738.html


文章标题:MySQL测试工具sysbench
文章来源:http://scyingshan.cn/article/jshejp.html