Re: ERROR: could not open file "pg_tblspc/ issue with replicationsetup. - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: ERROR: could not open file "pg_tblspc/ issue with replicationsetup.
Date
Msg-id 20200417041758.GJ81957@paquier.xyz
Whole thread Raw
In response to ERROR: could not open file "pg_tblspc/ issue with replication setup.  (Rajkumar Raghuwanshi <rajkumar.raghuwanshi@enterprisedb.com>)
Responses Re: ERROR: could not open file "pg_tblspc/ issue with replication setup.
List pgsql-hackers
On Thu, Apr 16, 2020 at 01:56:47PM +0530, Rajkumar Raghuwanshi wrote:
> While testing for a feature I got this tablespace related error while
> running script.

Primary and standby are running on the same host, so they would
interact with each other as the tablespace path used by both clusters
would be the same (primary uses the path defined by the DDL, which is
registered in the WAL record the standby replays).  What you are
looking for here is to create the tablespace before taking the base
backup, and then use the option --tablespace-mapping with
pg_basebackup to avoid the issue.
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: ikedamsh
Date:
Subject: It is not documented that pg_promote can exit standby mode
Next
From: Fujii Masao
Date:
Subject: Re: It is not documented that pg_promote can exit standby mode