Sysbench-dependent packages: M4 autoconf Automake Libtool
Yum Install M4 autoconf automake Libtool
Installation:
Tar zxvf sysbench-0.5.tar.gz
CD sysbench-0.5
chmod +x autogen.sh
./autogen.sh
./configure--with-mysql-includes=/usr/local/mysql/include--with-mysql-libs=/usr/local/mysql/lib
Make & make Install
To construct the data:
Sysbench--test=/usr/local/src/sysbench-0.5/sysbench/tests/db/oltp.lua--oltp_secondary=on--oltp_tables_count=10 --oltp-table-size=2000000--db-driver=mysql--mysql-user=root--mysql-password= ' superdata123 '--mysql-port=3306-- mysql-host= ' localhost '--mysql-db=test prepare
Test:
Sysbench--test=/usr/local/src/sysbench-0.5/sysbench/tests/db/oltp.lua--oltp-read-only=off--init-rng=on-- num-threads=100--max-requests=200000--oltp-dist-type=uniform--max-time=1800--mysql-user=superdata-- oltp-table-size=2000000--oltp_tables_count=10--rand-init=on--mysql-password= ' xxxx '--mysql-port=3306-- mysql-host= ' xxxxx '--db-driver=mysql--mysql-db=test Run
--oltp-read-only=on only Test Read
--init-rng=on if the random generator is initialized at the beginning of the test, the default is off
--num-thread number of concurrent connection threads
Error message:
Sysbench:error while loading shared libraries:libmysqlclient.so.18:cannot open Shared object file:no such file or dire Ctory
export ld_library_path=/usr/local/mysql/lib Output This variable can be
Test results Analysis
650) this.width=650; "Src=" https://s4.51cto.com/wyfs02/M01/8E/29/wKiom1i3jGHieS9JAABawHywh1E583.png-wh_500x0-wm_ 3-wmp_4-s_3490831340.png "title=" qq picture 20170302110706.png "alt=" Wkiom1i3jghies9jaabawhywh1e583.png-wh_50 "/>
This article is from the "11958098" blog, please be sure to keep this source http://11968098.blog.51cto.com/11958098/1902561
Sysbench 0.5 Installation and MySQL benchmark test