# Use --redo-only option when preparing a second incremental backup

**URL:** <https://forums.percona.com/t/use-redo-only-option-when-preparing-a-second-incremental-backup/2718>\
**Category:** Percona XtraBackup\
**Created:** [May 28, 2013, 9:03am UTC](https://forums.percona.com/t/use-redo-only-option-when-preparing-a-second-incremental-backup/2718 "2013-05-28T09:03:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jag](https://avatars.discourse-cdn.com/v4/letter/j/e56c9b/32.png) [@jag](https://forums.percona.com/u/jag)\
**Post date:** [May 28, 2013, 9:03am UTC](https://forums.percona.com/t/use-redo-only-option-when-preparing-a-second-incremental-backup/2718/1 "2013-05-28T09:03:25Z")

</div>

Hello,

in [http://www.percona.com/doc/percona-xtrabackup/1.6/innobackupex/incremental\_backups\_innobackupex.html](http://www.percona.com/doc/percona-xtrabackup/1.6/innobackupex/incremental_backups_innobackupex.html) we see that when executing --apply-log for the incremental backup the --redo option is omitted in the second incremental.

First we have:

> [@](#):
>
> innobackupex --apply-log --redo-only BASE-DIR --incremental-dir=INCREMENTAL-DIR-1

Then:

> [@](#):
>
> innobackupex --apply-log BASE-DIR --incremental-dir=INCREMENTAL-DIR-2

The lack of ‘–redo-only’ is a typo or it is necessary?.  
If it is not a typo what is the difference between the first and subsequents incremental backups which changes the procedure?

Thanks

---

<div class="post-metadata">

**Author:** ![mirfan](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/mirfan/32/16890_2.png) [@mirfan](https://forums.percona.com/u/mirfan)\
**Post date:** [May 28, 2013, 10:33pm UTC](https://forums.percona.com/t/use-redo-only-option-when-preparing-a-second-incremental-backup/2718/2 "2013-05-28T22:33:21Z")

</div>

–redo-only is not typo. The second backup with INCREMENTAL-DIR-2 assumed it’s the last backup.  
–redo-only option skips rollback and it should be excluded from the last backup. --redo-only option is used in full + incremental backup scheme.

Quoted from the manual:  
Note: --redo-only should be used when merging all incrementals except the last one. That’s why the previous  
line doesn’t contain the --redo-only option. Even if the --redo-only was used on the last step, backup would  
still be consistent but in that case server would perform the rollback phase.

---

<div class="post-metadata">

**Author:** ![jag](https://avatars.discourse-cdn.com/v4/letter/j/e56c9b/32.png) [@jag](https://forums.percona.com/u/jag)\
**Post date:** [May 29, 2013, 7:36am UTC](https://forums.percona.com/t/use-redo-only-option-when-preparing-a-second-incremental-backup/2718/3 "2013-05-29T07:36:09Z")

</div>

Thanks a lot for your answer, Mirfan.

The incremental backup was correctly restored. However I have another problem with incremental backup + partial backup, I will open other thread for it
