MYSQL 5.6恢复实录-- Percona XtraBackup
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了MYSQL 5.6恢复实录-- Percona XtraBackup相关的知识,希望对你有一定的参考价值。
king02 仅安装mysql 5.6软件无需建库 请参考《MYSQL 5.6源码编译安装实录》
king02 安装xtrabackup,请参考《MYSQL 5.6备份实录-- Percona XtraBackup》
[[email protected] ~]# mkdir -p /usr/local/mysql/backup
[[email protected] ~]# chown -R mysql /usr/local/mysql/backup
[[email protected] ~]# scp /etc/my.cnf [email protected]:/etc
[[email protected] ~]# su - mysql
[[email protected] ~]$ cd /usr/local/mysql/backup/
[[email protected] backup]$ scp -r 2018-02-04_03-00-01 [email protected]:/usr/local/mysql/backup
[[email protected] backup]$ scp -r 2018-02-05_03-00-01 [email protected]:/usr/local/mysql/backup
[[email protected] ~]# su - mysql
[[email protected] ~]$ innobackupex --defaults-file=/etc/my.cnf --apply-log --redo-only /usr/local/mysql/backup/2018-02-04_03-00-01/
[[email protected] ~]$ innobackupex --defaults-file=/etc/my.cnf --apply-log /usr/local/mysql/backup/2018-02-04_03-00-01/ --incremental-dir=/usr/local/mysql/backup/2018-02-05_03-00-01
[[email protected] ~]$ innobackupex --defaults-file=/etc/my.cnf --copy-back /usr/local/mysql/backup/2018-02-04_03-00-01/
[[email protected] ~]$ service mysqld start
Starting MySQL.. [ OK ]
[[email protected] ~]$ service mysqld status
MySQL running (15608)
以上是关于MYSQL 5.6恢复实录-- Percona XtraBackup的主要内容,如果未能解决你的问题,请参考以下文章
CentOS7.4 x64环境Percona-Server-5.6安装
Linux 下 YUM 安装 Percona Server 5.6
MySQL(Percona Server) 5.6 主从复制