From: Arnaud L. <arnaud.listes@codata.eu>
To: Adrian Klaver <adrian.klaver@aklaver.com>
To: Bruce Momjian <bruce@momjian.us>
Cc: PG-General Mailing List <pgsql-general@postgresql.org>
Subject: Re: pg_upgrade --link on Windows
Date: Fri, 9 Jun 2017 17:02:42 +0200
Message-ID: <a9320aea-1c9d-3e37-103e-88b7edcc2080@codata.eu> (raw)
In-Reply-To: <0405d125-929b-ab4a-b7be-d49c09e7c056@aklaver.com>
References: <8da3dbd9-7daf-5589-0cc8-0eede930a492@codata.eu>
<20170609140724.GB21215@momjian.us>
<a892509c-0eb4-42a4-1370-6cb0ac3bc1c3@codata.eu>
<0405d125-929b-ab4a-b7be-d49c09e7c056@aklaver.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-general>
Le 9/06/2017 à 16:55, Adrian Klaver a écrit :
> On 06/09/2017 07:39 AM, Arnaud L. wrote:
>> So maybe pg_upgrade uses hard-links (i.e. to files), and only the
>> documentation is wrong by calling them junctions (i.e. soft links to
>> files) ?
>
> Looks that way. In file.c in ~/src/bin/pg_upgrade I see:
>
> #ifdef WIN32
> 300 /* implementation of pg_link_file() on Windows */
> 301 static int
> 302 win32_pghardlink(const char *src, const char *dst)
> 303 {
> 304 /*
> 305 * CreateHardLinkA returns zero for failure
> 306 * http://msdn.microsoft.com/en-us/library/aa363860(VS.85).aspx
> 307 */
> 308 if (CreateHardLinkA(dst, src, NULL) == 0)
> 309 {
> 310 _dosmaperr(GetLastError());
> 311 return -1;
> 312 }
> 313 else
> 314 return 0;
> 315 }
> 316 #endif
Great !
So I did a full upgrade for nothing (just for safety), but that's good
to know for next time !
Should this be submitted to postgresql-bugs, or is there something more
specific to the documentation ?
Regards
--
Arnaud
--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general
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 using the --to and --cc options:
reply via email
To: pgsql-docs@postgresql.org
Cc: arnaud.listes@codata.eu, adrian.klaver@aklaver.com, bruce@momjian.us, pgsql-general@postgresql.org
Subject: Re: pg_upgrade --link on Windows
In-Reply-To: <a9320aea-1c9d-3e37-103e-88b7edcc2080@codata.eu>
* 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