From: Andrew Dunstan <andrew@dunslane.net>
To: pgsql-committers@postgresql.org
Subject: pgsql: Map basebackup tablespaces using a tablespace_map file
Date: Tue, 12 May 2015 13:42:56 +0000
Message-ID: <E1YsASW-0000Aa-Ut@gemulon.postgresql.org> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>
Map basebackup tablespaces using a tablespace_map file
Windows can't reliably restore symbolic links from a tar format, so
instead during backup start we create a tablespace_map file, which is
used by the restoring postgres to create the correct links in pg_tblspc.
The backup protocol also now has an option to request this file to be
included in the backup stream, and this is used by pg_basebackup when
operating in tar mode.
This is done on all platforms, not just Windows.
This means that pg_basebackup will not not work in tar mode against 9.4
and older servers, as this protocol option isn't implemented there.
Amit Kapila, reviewed by Dilip Kumar, with a little editing from me.
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/72d422a5227ef6f76f412486a395aba9f53bf3f0
Modified Files
--------------
doc/src/sgml/backup.sgml | 32 +--
doc/src/sgml/func.sgml | 14 +-
doc/src/sgml/protocol.sgml | 15 +-
doc/src/sgml/ref/pg_basebackup.sgml | 14 +-
src/backend/access/transam/xlog.c | 387 ++++++++++++++++++++++++++++++--
src/backend/access/transam/xlogfuncs.c | 12 +-
src/backend/replication/basebackup.c | 138 +++++-------
src/backend/replication/repl_gram.y | 16 +-
src/backend/replication/repl_scanner.l | 1 +
src/bin/pg_basebackup/pg_basebackup.c | 5 +-
src/include/access/xlog.h | 9 +-
src/include/replication/basebackup.h | 10 +
12 files changed, 519 insertions(+), 134 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: andrew@dunslane.net
Subject: Re: pgsql: Map basebackup tablespaces using a tablespace_map file
In-Reply-To: <E1YsASW-0000Aa-Ut@gemulon.postgresql.org>
References: <E1YsASW-0000Aa-Ut@gemulon.postgresql.org>
* 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