Skip to content

Bgrestore changes - #4

Open
michaeldg wants to merge 28 commits into
bstillman:masterfrom
michaeldg:master
Open

michaeldg wants to merge 28 commits into
bstillman:masterfrom
michaeldg:master

Conversation

@michaeldg

Copy link
Copy Markdown

If we try out bgbackup and bgrestore, you put everything on the same box. The bgrestgore configuration is much different, with this change they are the same.

@michaeldg michaeldg changed the title Make defaults the same as in bgbackup Bgrestore changes Apr 8, 2020
@michaeldg

Copy link
Copy Markdown
Author

I have ansible automation that sets upbgbackup and bgrestore. My restore dumps the backup into preppath to be restored. This way less space is needed but incremental backups are not supported in that mode.

michaeldg added 19 commits May 12, 2020 11:23
bgrestore's prepit()/restoreit() duplicated fgrestore's decrypt/decompress/
prepare/move-back logic with an older, non-chain-aware implementation.
bgrestore now only does what's genuinely its own (backup_history lookup,
logging, the MDEV-6660 workaround, starting the service) and hands the
actual restore to fgrestore, which is chain-aware (Full/Differential/
Incremental) and checks exit status at every step.

Also adds -c|--config CLI parsing and a service_name config variable
(replacing a hardcoded "mariadb" service) with a matching per-service lock
file, so restore tests can run against multi-instance hosts.
fgrestore is chain-aware now, so there's no reason to wait for the next
Full when the latest successful backup is a Differential or Incremental --
fgrestore trickles back to the Full on its own. Drops the butype = 'Full'
filter from the backup_history lookup and renames lastfullinfo()/
lastfulluuid/lastfullbulocation accordingly.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant