Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1i7Qto-00079i-5g for pgsql-general@arkaria.postgresql.org; Mon, 09 Sep 2019 21:08:36 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1i7Qtn-0000E3-0z for pgsql-general@arkaria.postgresql.org; Mon, 09 Sep 2019 21:08:35 +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_SHA1:256) (Exim 4.89) (envelope-from ) id 1i7Qtm-0000AH-Lp for pgsql-general@lists.postgresql.org; Mon, 09 Sep 2019 21:08:34 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1i7Qtk-0004Tz-KV for pgsql-general@lists.postgresql.org; Mon, 09 Sep 2019 21:08:34 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id x89L8T0M005179; Mon, 9 Sep 2019 17:08:29 -0400 From: Tom Lane To: "Daniel Verite" cc: "Cory Nemelka" , pgsql-general@lists.postgresql.org Subject: Re: Issues with inconsistent COLLATION installation In-reply-to: <0df13b3e-cc8b-41b7-ab78-487315a28a59@manitou-mail.org> References: <0df13b3e-cc8b-41b7-ab78-487315a28a59@manitou-mail.org> Comments: In-reply-to "Daniel Verite" message dated "Mon, 09 Sep 2019 22:46:29 +0200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <5177.1568063309.1@sss.pgh.pa.us> Date: Mon, 09 Sep 2019 17:08:29 -0400 Message-ID: <5178.1568063309@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk "Daniel Verite" writes: > I can reproduce this by creating a new locale *after* starting > PostgreSQL and trying to use it before a restart. That is interesting. I think it must mean that glibc's setlocale() and newlocale() maintain some kind of internal cache about available locales ... and there's no logic to flush it if /usr/share/locale changes. The individual backends are probably inheriting the cache state via fork from the postmaster. regards, tom lane