When sysbench is installed on ECS, an error is reported./libtool: line 841: X -- tag = CC: command not found, sysbenchlibtool

Source: Internet
Author: User

When sysbench is installed on ECS, an error is reported./libtool: line 841: X -- tag = CC: command not found, sysbenchlibtool

Background of important content. When sysbench is installed, make reports the following error:

./libtool: line 841: X--tag=CC: command not found../libtool: line 874: libtool: ignoring unknown tag : command not found../libtool: line 841: X--mode=link: command not found../libtool: line 1007: *** Warning: inferring the mode of operation is deprecated.: command not found../libtool: line 1008: *** Future versions of Libtool will require --mode=MODE be specified.: command not found../libtool: line 2234: X-g: command not found../libtool: line 2234: X-O2: command not found../libtool: line 1954: X-L/usr/local/mysql/lib: No such file or directory../libtool: line 2403: Xsysbench: command not found../libtool: line 2408: X: command not found../libtool: line 2415: Xsysbench: command not found../libtool: line 2550: X-lmysqlclient_r: command not found../libtool: line 2550: X-lrt: command not found../libtool: line 2550: X-lm: command not found../libtool: line 2632: X-L/data/sysbench-0.4.12/sysbench: No such file or directory../libtool: line 2550: X-lmysqlclient_r: command not found../libtool: line 2550: X-lrt: command not found../libtool: line 2550: X-lm: command not found../libtool: line 2632: X-L/data/sysbench-0.4.12/sysbench: No such file or directory../libtool: line 2550: X-lmysqlclient_r: command not found../libtool: line 2550: X-lrt: command not found../libtool: line 2550: X-lm: command not found
1. Possible causes:

(1) No dependent package libtool is installed
(2) incorrect version (libtool version is earlier)
(3) other reasons

<All Rights Reserved. This document can be reprinted, but the source address must be indicated by link. Otherwise, we will be held legally responsible.>
Original blog address: http://blog.csdn.net/mchdba/article/details/46381741
Original Author: Huang Shan (mchdba)

2. solution:

Install the dependent package libtool and libtoo to the new version, and replace autogen. sh with autoreconf. The method is as follows:

The last method is used here:

autoreconf -iconfiguremakemake install
3, and then configure will pass normally
[root@bizdb01 sysbench-0.4.12]# sysbench --helpsysbench: error while loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such file or directory[root@bizdb01 sysbench-0.4.12]# 
4. lib Error
[root@bizdb01 sysbench-0.4.12]# find / -name libmysqlclient.so.18/mnt/resource/mysql-5.6.12/libmysql/libmysqlclient.so.18/usr/local/mysql/lib/libmysqlclient.so.18[root@bizdb01 sysbench-0.4.12]# 

This indicates that sysbench cannot find the mysql database file, which is probably because the environment variable LD_LIBRARY_PATH is not set. After setting, the problem can be solved:

echo "export LD_LIBRARY_PATH=/usr/local/mysql/lib" >> /etc/profile/source /etc/profile/[root@bizdb01 sysbench-0.4.12]# echo "export LD_LIBRARY_PATH=/usr/local/mysql/lib" >> /etc/profile[root@bizdb01 sysbench-0.4.12]# source /etc/profile[root@bizdb01 sysbench-0.4.12]# [root@bizdb01 sysbench-0.4.12]# [root@bizdb01 sysbench-0.4.12]# sysbench --helpUsage:  sysbench [general-options]... --test=<test-name> [test-options]... commandGeneral options:  --num-threads=N            number of threads to use [1]  --max-requests=N           limit for total number of requests [10000]  --max-time=N               limit for total execution time in seconds [0]  --forced-shutdown=STRING   amount of time to wait after --max-time before forcing shutdown [off]  --thread-stack-size=SIZE   size of stack per thread [32K]  --init-rng=[on|off]        initialize random number generator [off]  --test=STRING              test to run  --debug=[on|off]           print more debugging info [off]  --validate=[on|off]        perform validation checks where possible [off]  --help=[on|off]            print help and exit  --version=[on|off]         print version and exitCompiled-in tests:  fileio - File I/O test  cpu - CPU performance test  memory - Memory functions speed test  threads - Threads subsystem performance test  mutex - Mutex performance test  oltp - OLTP testCommands: prepare run cleanup help versionSee 'sysbench --test=<name> help' for a list of options for each test.

[Root @ bizdb01 sysbench-0.4.12] #

     min:                                  0.01ms     avg:                                  3.40ms     max:                                 99.25ms     approx.  95 percentile:              19.00ms

Read 93.703 Mb Written 62.688 Mb Total transferred 156.39 Mb (23.951 Mb/sec)

5. You can use sysbench to perform a stress test on the server.
 time sysbench --test=oltp --oltp-test-mode=nontrx --mysql-table-engine=innodb  --mysql-user=root  --mysql-password=""  --db-driver=mysql --num-threads=1000 --max-requests=100000  --oltp-nontrx-mode=select --mysql-db=test  --oltp-table-size=1000000 --oltp-table-name=t1  --mysql-socket=/usr/local/mysql/mysql.sock prepare

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.