并行备份
innobackupex -p123123 --parallel= /backup
节流备份(节省IO)
innobackupex -p123123 --throttle= /backup
压缩备份
innobackupex -p123123 --compress /backup
innobackupex -p123123 --compress --compress-threads= /backup
innobackupex -p123123 --parallel= --compress --compress-threads= /backup
# 解压
wget http://www.quicklz.com/qpress-11-linux-x64.tar # ls
qpress
# mv qpress /usr/local/bin/ qpress -d test.qp ./
for bf in `find . -iname "*\.qp"`; do qpress -d $bf $(dirname $bf) && rm $bf; done
innobackupex --decompress /backup/--01_11--/
innobackupex --parallel= --decompress --11_11--/
流备份
# tar格式流备份
innobackupex -p123123 --stream=tar /backup innobackupex -p123123 --stream=tar /backup > /backup/back.tar
tar -ixvf /backup/back.tar innobackupex -p123123 --stream=tar /backup | gzip > /backup/fullback.tar.gz innobackupex -p123123 --stream=tar /tmp | ssh root@192.168.1.120 \ "cat - > /backup/bak.tar" # 备份到远程主机
- [] 免密登录
- [] innobackupex -p123123 --stream=tar /tmp | ssh root@192.168.1.120 \ "cat - > /backup/bak.tar"
- [] innobackupex -p123123 --stream=tar /tmp | ssh root@192.168.1.120 \ "gzip > /backup/dateFullBak.tar.gz"; # xbstream格式流备份
innobackupex -p123123 --stream=xbstream ./ > /backup/fullbak.xbstream
innobackupex -p123123 --stream=xbstream --compress ./ > /backup/fullbak.xbstream xbstream -x < bakup.xbstream
xbstream -x -C /backup/zsythink/ < fullbak.xbstream 备份到远程主机
> innobackupex -p123123 --stream=xbstream --compress /tmp | ssh root@192.168.1.120 "xbstream -x -C /backup/datafull"
转自
17、xtrabackup 常用备份功能与选项 - 侃豺小哥 - 博客园 https://www.cnblogs.com/kcxg/p/10382507.html
MySQL物理备份基本操作 - weixin_33869377的博客 - ****博客 https://blog.****.net/weixin_33869377/article/details/86997034
「转」xtrabackup新版详细说明 - billy鹏 - 博客园 https://www.cnblogs.com/billyxp/p/5305676.html