GET 24/7 LIVE HELP NOW

Announcement

Announcement Module
Collapse
No announcement yet.

Incremental recovery fails with non-InnoDB files

Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Incremental recovery fails with non-InnoDB files

    xtrabackup 2.1.5

    This is what I did:
    1) ssh -q -o BatchMode=yes -l user $IPMYSQL sudo innobackupex-1.5.1 --slave-info --defaults-file=/etc/my.cnf --stream=xbstream ./ 2> /tmp/log.log | pv -q -L15M | gzip - > /full/fullbackup.xbstream.gz
    2) ssh -q -o BatchMode=yes -l user $IPMYSQL sudo innobackupex-1.5.1 --incremental --incremental-lsn=8984740484737 --slave-info --defaults-file=/etc/my.cnf --stream=xbstream ./ 2> /tmp/log.log | pv -q -L15M | gzip - > /inc/incbackup.xbstream.gz
    3) cd /full/; gunzip --stdout fullbackup.xbstream.gz | xbstream -xv
    4) cd /inc/; gunzip --stdout incbackup.xbstream.gz | xbstream -xv
    5) cd /full; innobackupex --apply-log --redo-only .
    6) innobackupex --apply-log --redo-only . --incremental-dir /inc

    From 1 to 5 works perfectly, but at 6 it fails with:
    -----------------------------------------------------------------------
    InnoDB: Reading tablespace information from the .ibd files...
    InnoDB: Doing recovery: scanned up to log sequence number 8987779492352 (21 %)
    InnoDB: Doing recovery: scanned up to log sequence number 8987784735232 (43 %)
    InnoDB: Doing recovery: scanned up to log sequence number 8987789978112 (65 %)
    InnoDB: Doing recovery: scanned up to log sequence number 8987795220992 (86 %)
    131025 16:49:53 InnoDB: Starting an apply batch of log records to the database...
    InnoDB: Progress in percents: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
    InnoDB: Apply batch completed
    InnoDB: Doing recovery: scanned up to log sequence number 8987798361898 (99 %)
    131025 16:51:16 InnoDB: Starting an apply batch of log records to the database...
    InnoDB: Progress in percents: 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99
    InnoDB: Apply batch completed
    InnoDB: In a MySQL replication slave the last master binlog file
    InnoDB: position 403336565, file name mysql-bin.006299
    InnoDB: and relay log file
    InnoDB: position 403336710, file name /var/lib/mysql/data/relay.008143
    InnoDB: Last MySQL binlog file position 0 38791685, file name ./mysql-bin.005549

    [notice (again)]
    If you use binary log and don't use any hack of group commit,
    the binary log position seems to be:
    InnoDB: Last MySQL binlog file position 0 38791685, file name ./mysql-bin.005549

    xtrabackup: starting shutdown with innodb_fast_shutdown = 1
    131025 16:51:17 InnoDB: Starting shutdown...
    131025 16:51:19 InnoDB: Shutdown completed; log sequence number 8987798361898
    innobackupex: Starting to copy non-InnoDB files in '../inc/'
    innobackupex: to the full backup directory '/'
    innobackupex: Copying '../inc/xtrabackup_binlog_info' to '/full/xtrabackup_binlog_info'
    innobackupex: Copying '../inc/xtrabackup_slave_info' to 'full/xtrabackup_slave_info'
    innobackupex: Copying '../inc/cmssnc/cmss.frm' to '/full/cmssnc/cmss.frm'
    innobackupex: Error: copy failed: No existe el fichero o el directorio at /usr/bin/innobackupex line 2112.

    -----------------------------------------------------------------------

    If I check those last files: '../inc/cmssnc/cmss.frm' and /full/cmssnc/cmss.frm', both are the same as the have the same md5

    Is there any way to know why or what is failing?
    The apply log on the full backup ends perfectly.
    I am not using NFS.
    Can someone point me in some direction?

    Thanks!


  • #2
    Quoting from xtrabackup documentation "Warning:This procedure only affects XtraDB or InnoDB-based tables. Other tables with a different storage engine, e.g. MyISAM, will be copied entirely each time an incremental backup is performed."

    For more on it check innobackupex documentation and this link too which describes how percona xtrabackup works http://www.percona.com/doc/percona-x...kup_works.html

    Comment


    • #3
      Thanks mirfan,

      Yes, I already read about the way innobackupex copy MyISAM tables. That is not really a problem for me right now.
      My problem is that it fails while trying to do that copy (while applying incremental log). I am trying to do a script to automatically prepare my backups (full+incremental) but, as it seems to fail while copying MyISAM tables, the script just exits with error status.

      Comment


      • #4
        I found out the problem.
        I don't remember reading it in the documentation so I don't know if it is there and I didn't read it or it is not there so I write what I found out in case it is useful for someone.
        The problem is that with my xtrabackup/innobackupex version the incremental apply-log will fail to copy MyISAM files using a relaitve path, but it will work using the absolute path.

        Comment

        Working...
        X