Xtrabackup系列之:源码安装
一、检查依赖包
rpm -q cmake gcc gcc-c++ libaio libaio-devel automake autoconf bison libtool ncurses-devel libgcrypt-devel libev-devel libcurl-devel vim-common libev-devel |grep "not installed"
注意:需要注意的是libev-devel包在系统安装包中并没有,需要网上下载。
我的下载地址为
http://dl.fedoraproject.org/pub/epel/6/x86_64/Packages/l/libev-devel-4.03-3.el6.x86_64.rpm
http://dl.fedoraproject.org/pub/epel/6/x86_64/Packages/l/libev-4.03-3.el6.x86_64.rpm
rpm -ivh libgpg-error-devel-1.7-4.el6.x86_64.rpm
rpm -ivh libgcrypt-devel-1.4.5-12.el6_8.x86_64.rpm
rpm -ivh libidn-devel-1.18-2.el6.x86_64.rpm
rpm -ivh libcurl-devel-7.19.7-52.el6.x86_64.rpm
rpm -ivh libev-4.03-3.el6.x86_64.rpm
rpm -ivh libev-devel-4.03-3.el6.x86_64.rpm
二、解压xtrabackup安装包
tar -zxvf percona-xtrabackup-2.4.11.tar.gz
三、编译、安装
cd percona-xtrabackup-2.4.11
cmake -DBUILD_CONFIG=xtrabackup_release -DWITH_MAN_PAGES=OFF -DDOWNLOAD_BOOST=1 -DWITH_BOOST=/root/mysql-5.7.20/boost
注意:xtrabackup源码包没有可用boost,如果在安装mysql5.7.20时用的是带有boost的源码包,则可以借用mysql的boost路径安装
make && make install