Re: Latest checkpoint's NextOID - Mailing list pgsql-admin

From Scott Ribe
Subject Re: Latest checkpoint's NextOID
Date
Msg-id 8D4BB505-C111-446E-81F9-91EA382E9371@elevated-dev.com
Whole thread Raw
In response to Re: Latest checkpoint's NextOID  (Simon Riggs <simon@2ndquadrant.com>)
List pgsql-admin
On 25 September 2014 11:12, AL-Temimi, Muthana
<muthana.al-temimi@tu-harburg.hamburg.de> wrote:

> i’m using 9.1 PostgreSQL and looking for a function to write WAL to table in
> order to save all the data into database and to make a recovery on the 2nd
> DB Server.
>
>
>
> The idea is to help recovery on other server and get the same OID on the 2nd
> Server and that’s by using the Latest checkpoint's NextOID from the first
> Server.

Why not use WAL-shipping or streaming replication the normal way?

You do realize that everything that goes into tables goes into the WAL, so you write WAL into a table, the table gets
loggedto WAL, and then that WAL... That's just not going to work, unless you use an unlogged table, in which case you
havea replication/recovery mechanism which is inherently unreliable, which is pretty worthless. So the whole idea seems
tobe unrealistic. 

Now, if you want to log changes to tables into a table, that's doable via triggers, usually for audit purposes, but it
canbe used to keep replicas in synch. It's just that it's hard to imagine what you'd do that Slony-I doesn't already
do,assuming you even need its features as opposed to streaming replication. 

--
Scott Ribe
scott_ribe@elevated-dev.com
http://www.elevated-dev.com/
(303) 722-0567 voice






pgsql-admin by date:

Previous
From: Simon Riggs
Date:
Subject: Re: Latest checkpoint's NextOID
Next
From: Kevin Grittner
Date:
Subject: Re: Out of shared memory while creating a backup with pg_dump