Re: Simplifying replication - Mailing list pgsql-hackers

From Hannu Krosing
Subject Re: Simplifying replication
Date
Msg-id 1289067736.2313.1896.camel@hvost
Whole thread Raw
In response to Re: Simplifying replication  (Dimitri Fontaine <dimitri@2ndQuadrant.fr>)
Responses Re: Simplifying replication
List pgsql-hackers
On Sat, 2010-11-06 at 18:02 +0100, Dimitri Fontaine wrote:
> Hannu Krosing <hannu@2ndQuadrant.com> writes:
> > To make pg_basebackup.py self-sufficient it should also open 2nd
> > connection to the same master and make sure that all WAL files are
> > copied for the duration of base copy.
> 
> Excellent idea, will make that happen soon'ish.

Unitil I learned better, I thought that this is how SR is supposed to works ;)

btw, as next step you could backport this to 8.x and have most of the
benefits of SR. It should not be very hard to keep track of wal position
inside a pl/pythonu function and send one or more records back in form of

(walfile_name text, start_pos int, data bytea)

and then call this function from client every second to keep possible data 
loss down to 1 sec.

this lets you set up warm standby with nothing more than a postgresql 
superuser access to master (assuming right defaults in postgresql conf).

-- 
-------
Hannu Krosing
PostgreSQL Infinite Scalability and Preformance Consultant
PG Admin Book: http://www.2ndQuadrant.com/books/





pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: temporary functions (and other object types)
Next
From: "David E. Wheeler"
Date:
Subject: Re: Query Plan Columns