Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dJLTT-0000Yo-Rp for pgsql-general@arkaria.postgresql.org; Fri, 09 Jun 2017 15:05:19 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dJLTT-0004KQ-Ec for pgsql-general@arkaria.postgresql.org; Fri, 09 Jun 2017 15:05:19 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dJLR2-0007EI-Sc for pgsql-general@postgresql.org; Fri, 09 Jun 2017 15:02:48 +0000 Received: from serveurmail01.codata.be ([82.146.123.190]) by magus.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dJLQz-0003Ha-Mi for pgsql-general@postgresql.org; Fri, 09 Jun 2017 15:02:48 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by serveurmail01.codata.be (Postfix) with ESMTP id 5CAF0900CE; Fri, 9 Jun 2017 17:02:44 +0200 (CEST) X-Virus-Scanned: amavisd-new at serveurmail01.codata.be Received: from serveurmail01.codata.be ([127.0.0.1]) by localhost (serveurmail01.codata.be [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id yFyR3yAeXnqj; Fri, 9 Jun 2017 17:02:43 +0200 (CEST) Received: from [10.0.0.100] (38-179-112-217.fix.adsl.belcenter.be [217.112.179.38]) by serveurmail01.codata.be (Postfix) with ESMTPSA id 49882900CC; Fri, 9 Jun 2017 17:02:43 +0200 (CEST) Reply-To: arnaud.listes@codata.eu Subject: Re: pg_upgrade --link on Windows To: Adrian Klaver , Bruce Momjian Cc: PG-General Mailing List References: <8da3dbd9-7daf-5589-0cc8-0eede930a492@codata.eu> <20170609140724.GB21215@momjian.us> <0405d125-929b-ab4a-b7be-d49c09e7c056@aklaver.com> From: "Arnaud L." Message-ID: Date: Fri, 9 Jun 2017 17:02:42 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 MIME-Version: 1.0 In-Reply-To: <0405d125-929b-ab4a-b7be-d49c09e7c056@aklaver.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 8bit X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-general Precedence: bulk Sender: pgsql-general-owner@postgresql.org 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