sysbench安装使用

首页 论坛 安全运维 系统运维 sysbench安装使用

正在查看 1 个帖子:1-1 (共 1 个帖子)
  • 作者
    帖子
  • #31375
    飞飞侠
    版主
    #!/bin/bash
    
    useradd -s /sbin/nologin mysql
    mkdir /data/mysql/data -p
    mkdir /data/mysql/log -p
    alias cp=cp
    cp -f /root/my.cnf /etc
    tar -xzf /root/Percona-Server-5.6.15-rel63.0-519.Linux.x86_64.tar.gz -C /usr/local
    ln -s /usr/local/Percona-Server-5.6.15-rel63.0-519.Linux.x86_64 /usr/local/mysql
    ln -s /usr/lib64/libssl.so /usr/lib64/libssl.so.6
    ln -s /usr/lib64/libcrypto.so /usr/lib64/libcrypto.so.6
    cd /usr/local/mysql
    ./scripts/mysql_install_db --defaults-file=/etc/my.cnf --user=mysql
    cp /usr/local/mysql/support-files/mysql.server /etc/init.d/mysql
    ln -s /usr/local/mysql/bin/mysql /usr/bin/
    /etc/init.d/mysql start
    echo "/usr/local/mysql/lib" >> /etc/ld.so.conf.d/mysql-x86_64.conf
    ldconfig
    
    yum install -y libtool
    cd /root
    tar -xzf sysbench-0.4.12.tar.gz
    mkdir /opt/sysbench
    cd /root/sysbench-0.4.12
    ./configure --prefix=/opt/sysbench --with-mysql-includes=/usr/local/mysql/include/ --with-mysql-libs=/usr/local/mysql/lib
    
    alias cp=cp
    cp -f /usr/bin/libtool /root/sysbench-0.4.12
    
    make && make install
    
    ln -s /opt/sysbench/bin/sysbench /usr/bin/
    
正在查看 1 个帖子:1-1 (共 1 个帖子)
  • 哎呀,回复话题必需登录。
个人中心
购物车
优惠劵
今日签到
有新私信 私信列表
搜索