sysbench安装以及常见错误

1,环境要求:

     1,centos,gcc,gcc++

     如果没有安装gcc:错误提示:

        configure: error: no acceptable C compiler found in $PATH,

yum -y install gcc
yum -y install gcc-c++ 
yum install make

    
       2,如果没有安装libtool,make的时候 会报如下错误:

            ./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

            yum install libtool  然后执行:cp /usr/bin/libtool /usr/local/sysbench-0.4.12/libtool

     3,没有安装make :command make not found  

         yum install make

     4,安装:

        ./configure --with-mysql-includes=/usr/local/mysql/include --with-mysql-libs=/usr/local/mysql/lib

     5,make && make install

     6,sysbench: error while loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such file or directory

           cd /usr/local/mysql/lib    查看是否有libmysqlclient.so.18

          cd  /usr/lib/                      查看是否有libmysqlclient.so.18

         /usr/lib/  中没有libmysqlclient.so.18 则做软链接

           ln -s /usr/local/mysql/lib/libmysqlclient.so.18 /usr/lib

            执行:sysbench -V  安装成功

      


转载于:https://my.oschina.net/lnmpstudy/blog/201661

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值