Re: Replication - Mailing list pgsql-hackers

From mlw
Subject Re: Replication
Date
Msg-id 3C627887.CC9FF837@mohawksoft.com
Whole thread Raw
In response to Re: Replication  (Gavin Sherry <swm@linuxworld.com.au>)
Responses Re: Replication  (F Harvell <fharvell@fts.net>)
Re: Replication  (Randall Jonasz <rjonasz@trueimpact.com>)
List pgsql-hackers
Gavin Sherry wrote:
> Naturally, this would slow down writes to the system (possibly a lot
> depending on the performance difference between the executing machine and
> the least powerful machine in the cluster), but most usages of postgresql
> are read intensive, not write.
> 
> Any reason this model would not work?

What, then is the purpose of replication to multiple masters?

I can think of only two reasons why you want replication. (1) Redundancy, make
sure that if one server dies, then another server has the same data and is used
seamlessly. (2) Increase performance over one system.

In reason (1) I submit that a server load balance which sits on top of
PostgreSQL, and executes writes on both servers while distributing reads would
be best. This is a HUGE project. The load balancer must know EXACTLY how the
system is configured, which includes all functions and everything. 

In reason (2) your system would fail to provide the scalability that would be
needed. If writes take a long time, but reads are fine, what is the difference
between the trigger based replicator?

I have in the back of my mind, an idea of patching into the WAL stuff, and
using that mechanism to push changes out to the slaves.

Where one machine is still the master, but no trigger stuff, just a WAL patch.
Perhaps some shared memory paradigm to manage WAL visibility? I'm not sure
exactly, the idea hasn't completely formed yet.


pgsql-hackers by date:

Previous
From: "Marc G. Fournier"
Date:
Subject: Re: Threaded PosgreSQL server
Next
From: Brian Bruns
Date:
Subject: Re: DRDA, network protocol, and documentation