4.1.8 Incremental Backup Options

For an overview of incremental backups and usage information about these options, see Section 3.3.2, “Making an Incremental Backup”.

To take an incremental backup, specify the --incremental or --incremental-with-redo-log-only, along with the --incremental-backup-dir. All InnoDB data modified after the specified LSN is copied in the incremental backup. Depending on the choice of --incremental or --incremental-with-redo-log-only other options are required or recommended.

Example 4.4 Incremental Backup

These examples show typical combinations of options used for incremental backups.

mysqlbackup --incremental \
  --incremental-backup-dir=/var/mysql/backup/latest \
  --incremental-base=dir:/var/mysql/backup/previous \
  ... backup

mysqlbackup --incremental-with-redo-log-only \
  --incremental-backup-dir=/var/mysql/backup/latest \
  --incremental-base=dir:/var/mysql/backup/previous \
  ... backup

mysqlbackup --incremental --start-lsn=12345 \
  --incremental-backup-dir=/var/mysql/backup/inc \
  ... backup

mysqlbackup --incremental-with-redo-log-only --start-lsn=12345 \
  --incremental-backup-dir=/var/mysql/backup/inc \
  ... backup