zoukankan      html  css  js  c++  java
  • INNOBACKUPEX热备MYSQL数据

    http://www.databaseclub.com/2014/11/innobackupex/

    1)对MySQL进行全备份
    1.备份数据

    2.准备恢复数据

    3.将准备好的数据恢复到MySQL数据目录
    注意:MySQL的datadir必须为空,否则会出现错误

    4.修改拷贝回去的数据权限:

    5.重启MySQL服务器

    2)对MySQL进行增量备份
    1.对MySQLl进行全备份

    2.对MySQL进行增量备份

    3.准备恢复数据

    这个地方需要注意,在非最后一个增量时,一定要添加上–redo-only参数
    –redo-only
    This option should be used when preparing the base full backup and
    when merging all incrementals except the last one. This option is
    passed directly to xtrabackup’s –apply-log-only option. This forces
    xtrabackup to skip the “rollback” phase and do a “redo” only. This
    is necessary if the backup will have incremental changes applied to
    it later. See the xtrabackup documentation for details.
    4.将准备好的数据恢复到MySQL数据目录

    5.修改拷贝回去的数据权限

    6.重启MySQL服务

    通过上面的几个步骤,我们就可以进行MySQL的热备以及数据恢复了,当然了还会有很多常用的选项没有进行介绍,请大家自行参考Percona的官方文档



     
  • 相关阅读:
    自然数幂和的若干种解法
    线性预处理逆元
    差分与有限微积分
    UVALive 6859——凸包&&周长
    UVALive 6858——分类讨论&&水题
    UVALive 6862——结论题&&水题
    ZOJ4019——贪心&&DP
    [LeetCode] Power of Two
    循环队列实现(C++) Ring Buffer
    正确使用stl vecotr erase函数
  • 原文地址:https://www.cnblogs.com/zengkefu/p/5678292.html
Copyright © 2011-2022 走看看