Thread: pgsql: Cascading replication feature for streaming log-based replicatio

pgsql: Cascading replication feature for streaming log-based replicatio

From
Simon Riggs
Date:
Cascading replication feature for streaming log-based replication.
Standby servers can now have WALSender processes, which can work with
either WALReceiver or archive_commands to pass data. Fully updated
docs, including new conceptual terms of sending server, upstream and
downstream servers. WALSenders terminated when promote to master.

Fujii Masao, review, rework and doc rewrite by Simon Riggs

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/5286105800c7d5902f98f32e11b209c471c0c69c

Modified Files
--------------
doc/src/sgml/config.sgml              |  127 ++++++++++------
doc/src/sgml/high-availability.sgml   |   62 ++++++++-
src/backend/access/transam/xlog.c     |  265 +++++++++++++++++++--------------
src/backend/postmaster/postmaster.c   |   20 +++
src/backend/replication/basebackup.c  |    5 +
src/backend/replication/syncrep.c     |    7 +
src/backend/replication/walreceiver.c |    7 +-
src/backend/replication/walsender.c   |  108 ++++++++++---
src/include/access/xlog.h             |    6 +-
src/include/replication/walsender.h   |    5 +-
10 files changed, 423 insertions(+), 189 deletions(-)


Re: pgsql: Cascading replication feature for streaming log-based replicatio

From
Thom Brown
Date:
On 19 July 2011 03:44, Simon Riggs <simon@2ndquadrant.com> wrote:
> Cascading replication feature for streaming log-based replication.
> Standby servers can now have WALSender processes, which can work with
> either WALReceiver or archive_commands to pass data. Fully updated
> docs, including new conceptual terms of sending server, upstream and
> downstream servers. WALSenders terminated when promote to master.
>
> Fujii Masao, review, rework and doc rewrite by Simon Riggs

I've only just started looking at this.

In doc/src/sgml/config.sgml:

Note that in addition to these parameters,
<xref linkend="guc-wal-level"> must be set appropriately on the master
server, and may also want to enable WAL archiving as
well (see <xref linkend="runtime-config-wal-archiving">).

s/and may also/and you may also/


In doc/src/sgml/high-availability.sgml:

s/effected/affected/

Also: "i.e., set max_wal_senders, hot_standby and authentication option"

Doesn't sound right.  Perhaps something like "... and configure
host-based authentication"


In src/backend/postmaster/postmaster.c:

(errmsg("terminating walsender all processes to force cascaded"
        "standby(s) to update timeline and reconnect")));

s/walsender all/all walsender/

--
Thom Brown
Twitter: @darkixion
IRC (freenode): dark_ixion
Registered Linux user: #516935

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Re: pgsql: Cascading replication feature for streaming log-based replicatio

From
Robert Haas
Date:
On Sat, Oct 8, 2011 at 8:59 AM, Thom Brown <thom@linux.com> wrote:
> s/and may also/and you may also/

This was already fixed in a later commit.

> In doc/src/sgml/high-availability.sgml:
>
> s/effected/affected/

I fixed this.

> Also: "i.e., set max_wal_senders, hot_standby and authentication option"
>
> Doesn't sound right.  Perhaps something like "... and configure
> host-based authentication"

I reworded this.  See what you think.

> In src/backend/postmaster/postmaster.c:
>
> (errmsg("terminating walsender all processes to force cascaded"
>        "standby(s) to update timeline and reconnect")));
>
> s/walsender all/all walsender/

This has also been subsequently fixed.  Nothing to see here, folks.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Re: pgsql: Cascading replication feature for streaming log-based replicatio

From
Thom Brown
Date:
On 10 October 2011 15:18, Robert Haas <robertmhaas@gmail.com> wrote:
> On Sat, Oct 8, 2011 at 8:59 AM, Thom Brown <thom@linux.com> wrote:
>> s/and may also/and you may also/
>
> This was already fixed in a later commit.
>
>> In doc/src/sgml/high-availability.sgml:
>>
>> s/effected/affected/
>
> I fixed this.
>
>> Also: "i.e., set max_wal_senders, hot_standby and authentication option"
>>
>> Doesn't sound right.  Perhaps something like "... and configure
>> host-based authentication"
>
> I reworded this.  See what you think.
>
>> In src/backend/postmaster/postmaster.c:
>>
>> (errmsg("terminating walsender all processes to force cascaded"
>>        "standby(s) to update timeline and reconnect")));
>>
>> s/walsender all/all walsender/
>
> This has also been subsequently fixed.  Nothing to see here, folks.

Ah, didn't spot that some of this had already been addressed.  Looks
good to me.  Cheers.

--
Thom Brown
Twitter: @darkixion
IRC (freenode): dark_ixion
Registered Linux user: #516935

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company