From: Simon Riggs <simon@2ndquadrant.com>
To: Jeff Frost <jeff@frostconsultingllc.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: archive_command
Date: Tue, 04 Oct 2005 17:09:55 +0100
Message-ID: <1128442195.8603.324.camel@localhost.localdomain> (raw)
In-Reply-To: <Pine.LNX.4.63.0510040759100.9849@discord.dyndns.org>
References: <20031115132118.V74587@holywar.net>
<433AC059.1050300@musicrebellion.com>
<Pine.LNX.4.63.0509280925070.28080@discord.dyndns.org>
<433ACE02.3040208@musicrebellion.com>
<1128071627.19345.256.camel@localhost.localdomain>
<Pine.LNX.4.63.0509300926340.1280@discord.dyndns.org>
<1128113968.4045.32.camel@localhost.localdomain>
<Pine.LNX.4.63.0510012142210.13614@discord.dyndns.org>
<1128246295.3717.76.camel@localhost.localdomain>
<Pine.LNX.4.63.0510031950290.10454@discord.dyndns.org>
<1128420570.8603.279.camel@localhost.localdomain>
<Pine.LNX.4.63.0510040759100.9849@discord.dyndns.org>
On Tue, 2005-10-04 at 08:03 -0700, Jeff Frost wrote:
> >> Is there any possible way to replay the other WAL files after the Sep 21
> >> switchover/switchback? I'm going to guess this is similar to having another
> >> timeline.
> >
> > That may be your exact case, it depends upon how you did recovery. Both
> > systems think they are the same one, so you need to be careful.
> >
> > Look for the last log file of the went-down node. That file should exist
> > twice, once as finally written by the went-down node and once as
> > continued to be written to by the stayed-up node after switchover. It
> > sounds like the wrong file was used to recover with and as a result
> > stopped recovery on Sep 21. But if you're running with the system now,
> > you'll need to do an intermediate rebuild and recover the data manually.
>
> What would constitute an intermediate rebuild? Of course the system is up and
> live and having data added to it. How would one restore from multiple
> timelines?
This is only if you are back up and working on the went-down box:
intermediate rebuild: I mean that you will have to restore the data from
the period of switchover, manually extract the relevant data with SQL
and then re-insert those changes yourself and resolve conflicts.
There isn't a process to merge the two log streams. The same txnid will
have been used on both servers to refer to separate transactions, so
there can be no automated way of resolving the data. It has to be done
using business domain knowledge rather than log data.
All of that's no different from any other RDBMS, as I'm sure you know.
Best Regards, Simon Riggs
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-admin@postgresql.org
Cc: simon@2ndquadrant.com, jeff@frostconsultingllc.com
Subject: Re: archive_command
In-Reply-To: <1128442195.8603.324.camel@localhost.localdomain>
References: <20031115132118.V74587@holywar.net> <433AC059.1050300@musicrebellion.com> <Pine.LNX.4.63.0509280925070.28080@discord.dyndns.org> <433ACE02.3040208@musicrebellion.com> <1128071627.19345.256.camel@localhost.localdomain> <Pine.LNX.4.63.0509300926340.1280@discord.dyndns.org> <1128113968.4045.32.camel@localhost.localdomain> <Pine.LNX.4.63.0510012142210.13614@discord.dyndns.org> <1128246295.3717.76.camel@localhost.localdomain> <Pine.LNX.4.63.0510031950290.10454@discord.dyndns.org> <1128420570.8603.279.camel@localhost.localdomain> <Pine.LNX.4.63.0510040759100.9849@discord.dyndns.org> <1128442195.8603.324.camel@localhost.localdomain>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox