Re: pg_basebackup or dump for starting replication process - Mailing list pgsql-general

From Laurenz Albe
Subject Re: pg_basebackup or dump for starting replication process
Date
Msg-id 1522995896.2420.3.camel@cybertec.at
Whole thread Raw
In response to pg_basebackup or dump for starting replication process  (PegoraroF10 <marcos@f10.com.br>)
List pgsql-general
PegoraroF10 wrote:
> For replication purposes only, there are any difference between pg_basebackup
> or dump to copy data from Master to Slave ?
> On Docs is written that pg_basebackup can be used both for point-in-time
> recovery and as the starting point for a log shipping or streaming
> replication standby servers.
> 
> We are using just Dump, there are any caveat of using it for logical
> replication ?

For *logical* replication you can start with a "pg_dump --schema-only",
but for *physical* replication only a pg_basebackup will do.

Make sure that he tables are empty before you start logical replication.

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com


pgsql-general by date:

Previous
From: Pavan Deolasee
Date:
Subject: Re: ERROR: unexpected chunk number 0 (expected 1) for toast value76753264 in pg_toast_10920100
Next
From: hmidi slim
Date:
Subject: Extract dates of a given day