pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Oleksii Kliukin <oleksii@fastmail.com>
To: Stephen Frost <sfrost@snowman.net>
Cc: pgsql-admin@postgresql.org
Subject: Re: 'replication checkpoint has wrong magic' on the newly cloned replicas
Date: Wed, 29 Nov 2017 18:41:24 +0100
Message-ID: <CFFC01E6-FE97-4490-8D39-903BB910AB85@fastmail.com> (raw)
In-Reply-To: <20171129145455.GL4628@tamriel.snowman.net>
References: <1511966240.1459861.1188109744.2D26AD08@webmail.messagingengine.com>
	<20171129145455.GL4628@tamriel.snowman.net>

Hi Stephen, 

> On 29. Nov 2017, at 15:54, Stephen Frost <sfrost@snowman.net> wrote:
> 
> Greetings,
> 
> * Alex Kliukin (alexk@hintbits.com) wrote:
>> The cloning itself is done by copying a compressed image via ssh,
>> running the
>> following command from the replica:
>> 
>> """ssh {master} 'cd {master_datadir} && tar -lcp --exclude "*.conf" \
>>         --exclude "recovery.done" \
>>         --exclude "pacemaker_instanz" \
>>         --exclude "dont_start" \
>>         --exclude "pg_log" \
>>         --exclude "pg_xlog" \
>>         --exclude "postmaster.pid" \
>>         --exclude "recovery.done" \
>>           * | pigz -1 -p 4' | pigz -d -p 4 | tar -xpmUv -C
>>           {slave_datadir}""
>> 
>> The WAL archiving starts before the copy starts, as the script that
>> clones the
>> replica checks that the WALs archiving is running before the cloning.
> 
> Maybe you've doing it and haven't mentioned it, but you have to use
> pg_start/stop_backup

Sorry for not mentioning it, as it seemed obvious, but we are calling pg_start_backup and pg_stop_backup at the right time.

Cheers,
Alex




view thread (15+ messages)  latest in thread

Message-ID: <CFFC01E6-FE97-4490-8D39-903BB910AB85@fastmail.com>
Permalink:  ../CFFC01E6-FE97-4490-8D39-903BB910AB85@fastmail.com/
Also on:    postgresql.org/message-id/CFFC01E6-FE97-4490-8D39-903BB910AB85@fastmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: oleksii@fastmail.com, sfrost@snowman.net
  Subject: Re: 'replication checkpoint has wrong magic' on the newly cloned replicas
  In-Reply-To: <CFFC01E6-FE97-4490-8D39-903BB910AB85@fastmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox