Re: pg_basebackup vs. Windows and tablespaces

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, Noah Misch <noah(at)leadboat(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: pg_basebackup vs. Windows and tablespaces
Date: 2014-11-14 18:33:00
Message-ID: 20141114183300.GM1791@alvin.alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Amit Kapila wrote:

> 2. Symlink file format:
> <oid> <linkpath>
> 16387 E:\PostgreSQL\tbs
>
> Symlink file will contain entries for all the tablspaces
> under pg_tblspc directory. I have kept the file name as
> symlink_label (suggestion are welcome if you want some
> different name for this file).

I think symlink_label isn't a very good name. This file is not a label
in the sense that backup_label is; it seems more a "catalog" to me. And
it's not, in essence, about symlinks either, but rather about
tablespaces. I would name it following the term "tablespace catalog" or
some variation thereof.

I know we don't expect that users would have to look at the file or edit
it in normal cases, but it seems better to make it be human-readable. I
would think that the file needs to have tablespace names too, then, not
just OIDs. Maybe we don't use the tablespace name for anything other
than "documentation" purposes if someone decides to look at the file, so
perhaps it should look like a comment:

<oid> <link path> ; <tablespace name>

We already do this in pg_restore -l output IIRC.

One use case mentioned upthread is having the clone be created in the
same machine as the source server. Does your proposal help with it?

--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2014-11-14 18:42:05 Re: PostgreSQL doesn't stop propley when --slot option is specified with pg_receivexlog.
Previous Message Robert Haas 2014-11-14 18:31:21 Re: pg_basebackup vs. Windows and tablespaces