Re: Trouble with replication

From: David Greco <David_Greco(at)harte-hanks(dot)com>
To: John R Pierce <pierce(at)hogranch(dot)com>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Trouble with replication
Date: 2013-06-05 22:23:16
Message-ID: 187F6C10D2931A4386EE8E58E13857F6303FC720@BY2PRD0811MB415.namprd08.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

From: pgsql-general-owner(at)postgresql(dot)org [pgsql-general-owner(at)postgresql(dot)org] on behalf of John R Pierce [pierce(at)hogranch(dot)com]
Sent: Wednesday, June 05, 2013 5:00 PM
To: pgsql-general(at)postgresql(dot)org
Subject: Re: [GENERAL] Trouble with replication

On 6/5/2013 1:39 PM, David Greco wrote:
I’ve setup two 9.2.4 servers to serve as master-slave in a streaming replication scenario. I started with a fresh database on the master, setup the replication, then imported using pg_restore about 30GB of data. The master and slave are geographically separated, so replication of this amount of data can/should take hours. I saw from pg_last_xlog_receive_location and pg_last_xlog_replay_location that the slave began to receive the replication information, it eventually quit with the following errors in the log:

2013-06-05 16:28:43.198 EDT,,,19978,,51af9f7a.4e0a,2,,2013-06-05 16:28:42 EDT,,0,FATAL,XX000,"could not receive data from WAL stream: FATAL: requested WAL segment 000000010000000000000022 has already been removed
",,,,,,,,,""

I suspect you'll need to set the parameter that controls how many WAL log files are kept on the server high enough to cover this replication catchup period.

geographically separated high latency connections are very problematic for any sort of replication.

On the master or on the slave, or on both? I thought shipping the archived WAL files from the master to the slave did this already?

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message BladeOfLight16 2013-06-06 00:05:18 Re: [postgis-users] point_ops with GiST PostGIS Spatial Index
Previous Message David Johnston 2013-06-05 21:14:04 Re: Function use in query