Skip site navigation (1) Skip section navigation (2)

Re: [HACKERS] Moving tablespaces

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Bruce Momjian <bruce(at)momjian(dot)us>, PostgreSQL-documentation <pgsql-docs(at)postgresql(dot)org>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [HACKERS] Moving tablespaces
Date: 2011-12-06 14:59:11
Message-ID: CABUevEyP-20VSpgBP9J16=vk9-fxj8O6KPr63r9jQxHoca9JeA@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-docspgsql-hackers
On Sun, Dec 4, 2011 at 18:07, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Andrew Dunstan <andrew(at)dunslane(dot)net> writes:
>> On 12/04/2011 11:41 AM, Tom Lane wrote:
>>> Hm, how portable is symlink-reading?  If we can actually do that
>>> without big headaches, then +1.
>
>> I wondered that, specifically about Windows junction points, but we seem
>> to have support for it already in dirmod.c::pgreadlink(). Surely there's
>> no other currently supported platform where it would even be a question?
>
> readlink is required by Single Unix Spec v2 (1997), which is what we've
> been treating as our baseline expectation for Unix-oid platforms for
> awhile now.  Given that we dealt with the Windows side already, I don't
> see a problem with making this assumption.  At worst we'd end up needing
> a couple more emulations in src/port, since surely there's *some* way to
> do it on any platform with symlinks.

AFAICT, it should be as simple as the attached.

Doesn't include the required fixes for pg_upgrade, I'll get on those next.

-- 
 Magnus Hagander
 Me: http://www.hagander.net/
 Work: http://www.redpill-linpro.com/

Attachment: spclocation.diff
Description: text/x-patch (9.7 KB)

In response to

Responses

pgsql-docs by date

Next:From: Tom LaneDate: 2011-12-06 15:05:46
Subject: Re: [HACKERS] Moving tablespaces
Previous:From: Magnus HaganderDate: 2011-12-06 10:03:44
Subject: Re: pg_stat_get_wal_senders documented

pgsql-hackers by date

Next:From: Tom LaneDate: 2011-12-06 15:05:46
Subject: Re: [HACKERS] Moving tablespaces
Previous:From: Robert HaasDate: 2011-12-06 13:55:29
Subject: Re: pg_upgrade if 'postgres' database is dropped

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group