Documentation Home
MySQL Enterprise Backup 4.0 User's Guide
Related Documentation Download this Manual
PDF (US Ltr) - 1.2Mb
PDF (A4) - 1.2Mb
HTML Download (TGZ) - 182.8Kb
HTML Download (Zip) - 213.9Kb

14.2 Update Operations

There are two types of operations to bring your backup data up-to-date:

Apply-log Operation

After a backup job was first completed, the backup data might not be in a consistent state, because data could have been inserted, updated, or deleted while the backup was running. This initial backup file is known as the raw backup. During a backup, mysqlbackup also copies the accumulated InnoDB log to a file called ibbackup_logfile. In an apply-log operation, the ibbackup_logfile file is used to roll forward the raw data files, so that every page in the data files corresponds to the same log sequence number of the InnoDB log. This is similar to the operation that takes place during a crash recovery.

For single-file backups, the apply-log operation is usually performed as part of the copy-back-and-apply-log command. For directory backups, the copy-back-and-apply-log command can also be used, but you also have the two alternatives of

  • Performing the apply-log operation together with the back up using the backup-and-apply-log command (not applicable for incremental or compressed directory backups)

  • Performing the apply-log operation separately with the apply-log command on the raw backup, before running the copy-back command.

mysqlbackup [STD-OPTIONS]
            [--limit-memory=MB] [--uncompress] [--backup-dir=PATH]
  • apply-log

    Advanced: Brings the InnoDB tables in the directory backup up-to-date, including any changes made to the data while the backup was running.

Example 14.1 Apply Log to Full Backup

mysqlbackup --backup-dir=/path/to/backup apply-log

It reads the backup-my.cnf file inside backup-dir to understand the backup. The my.cnf default files have no effect other than supplying the limit-memory=MB value, which limits usage of memory while doing the apply-log operation.

Apply-incremental-backup Operation

Advanced: Use the apply-incremental-backup to update a backup directory with data in an incremental backup directory:

mysqlbackup [STD-OPTIONS]
            [--incremental-backup-dir=PATH] [--backup-dir=PATH]
            [--limit-memory=MB] [--uncompress]

User Comments
Sign Up Login You must be logged in to post a comment.