Re: PostgreSQL 12 installation fails because locale name contained non-english characters

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <bruce(at)momjian(dot)us>
Cc: "Skjalg A(dot) Skagen" <skjalg(dot)skagen(at)pm(dot)me>, "pgsql-bugs(at)lists(dot)postgresql(dot)org" <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: PostgreSQL 12 installation fails because locale name contained non-english characters
Date: 2019-11-05 17:22:21
Message-ID: 11659.1572974541@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

Bruce Momjian <bruce(at)momjian(dot)us> writes:
> On Thu, Oct 24, 2019 at 11:06:01AM +0000, Skjalg A. Skagen wrote:
>> I tried to install PostgreSQL 12 with the "Norwegian Bokmål, Norway" locale in
>> hope that it would, among other things, provide proper support for Norwegian
>> characters out-of-the-box.
>> But initcluster.vbs appear to fail during post-install because the locale name
>> contains a Norwegian character that is being mishandled (full log in attached
>> zip file):
>> initdb: error: invalid locale name "NorwegianBokm†l,Norway"

> This has been fixed with the this patch:
> https://www.postgresql.org/message-id/E1iMcHC-0007Ci-7G@gemulon.postgresql.org

Hm, I'm not entirely sure that it has been. The original code supposed
that the locale name is spelled "Norwegian (Bokmål)_Norway", and the
recent patch you mention extended that to allow "Norwegian Bokmål_Norway".
But this report, if accurate, shows yet another variant. Skjalg,
would you confirm that there's a comma and space before "Norway" in
the locale name as you see it? (Your log clearly shows it with a
space in the registry entries, but it looks like initdb might be
seeing it as not having any spaces, which is why I'm confused.)

I wonder whether we need to relax the matching code to be entirely
agnostic about spaces and punctuation in the Windows locale name.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2019-11-05 17:38:32 Re: BUG #16095: Segfault while executing trigger
Previous Message Pavel Stehule 2019-11-05 16:28:01 Re: BUG #16046: xpath returns CDATA tag along with the value in postgres 12

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrey Lepikhov 2019-11-05 18:20:28 Re: Removing unneeded self joins
Previous Message Tom Lane 2019-11-05 17:00:42 Re: d25ea01275 and partitionwise join