On Aug 11, 6:15 pm, Paul Dowman <
li...@pauldowman.com> wrote:
> The restore should also restore the binary logs (i.e. the incremental
> backup). One caveat is
> the database needs to have the same name when you're restoring it.
> It does work, let me know if you're having a problem and please give more
> detail.
What I was confused about is mainly the steps to restore the daily
backup, versus restoring a backup I'd done myself using the 'archive'
task.
I have been able to do a manual database archive using the cap
'archive' task on one box, and then the cap 'restore' task on another
box. This worked fine for me. Before running the restore, I just
edited the deploy.rb and pointed it to the archive bucket I had
previously archived to on the old box.
So, for restoring the daily backup, what cap task do I use? Still the
'restore' task? I just point it at the daily backup bucket, and it
will process the binary logs too?
> I didn't quite understand if you've noticed that the restored data
> actually isn't there or if you're just confused about how the binary logs
> work.
Possibly a bit of both :-) The problem I'm referring to is the status
of the daily backup on the *target* box, after a restore is done - in
other words the capability of the target, newly restored box to
respond to a failure on that box. These are the steps I did and the
problem I saw:
1) cap archive task on old box
2) bring up new box and run cap setup etc (now the app is running, but
with an empty database - no user activity so nothing being added,
modified or deleted) - all fine so far
3) repopulate the DB using cap restore, from the archive I'd manually
created (*not* the daily backup) on the old box - this works too
4) now, looking at the new box the DB is restored OK, the app works
etc, *but* the current daily backup data on the new box looked like it
couldn't possibly include the data I'd just restored. This is because
adding up the sizes of the daily dump (done prior to the archive
restore), plus the sizes of the binary logs copied to S3 since the
archive restore, they were way too small to represent a full data set.
It looked to me like the daily backup would only catch up on the next
full daily dump.
Another backup related question, is what happens if the incremental
backup fails due to a transient error on S3, which happens sometimes?
Does it catch up the next time it successfully runs the incremental or
is there a possibility of being missing a binary log?
Cheers,
Frank