Re: lc_collate mess

From: Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
To: Susanne & Udo Krause <su(dot)krause(at)bluewin(dot)ch>, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: lc_collate mess
Date: 2020-11-23 07:05:51
Message-ID: 29d8f00e-eb74-db6e-e4c3-0a3b26689f3b@iki.fi
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 22/11/2020 15:31, Susanne & Udo Krause wrote:
> the new PostgreSQL has been created from scratch by standard
> installation with German_Switzerland, then it does not know:
>
> ------------------------------------------------------------------------
>
> C:\Users\postgres\Documents>pg_upgrade.exe --old-datadir "C:/Program
> Files/PostgreSQL/12/data" --new-datadir "C:/Program
> Files/PostgreSQL/13/data" --old-bindir "C:/Program
> Files/PostgreSQL/12/bin" --new-bindir "C:/Program
> Files/PostgreSQL/13/bin" --check
> Führe Konsistenzprüfungen durch
> -------------------------------
> Checking cluster versions                                   ok
> Checking database user is the install user                  ok
> Checking database connection settings                       ok
> Checking for prepared transactions                          ok
> Checking for reg* data types in user tables                 ok
> Checking for contrib/isn with bigint-passing mismatch       ok
>
> lc_collate-Werte für Datenbank »postgres« stimmen nicht überein: alt
> »German_Switzerland.1252«, neu »German_Germany.1252«
> Fehlgeschlagen, Programm wird beendet
>
> C:\Users\postgres\Documents>
>
> ------------------------------------------------------------------------
>
>
> where is a hint how to fix that? New PostgreSQL did not yet start up, of
> course.

The error message suggests that the old database was initialized with
"German_Switzerland.1252" locale, and the new one with
"German_Germany.1252". The new database needs to initialized with the
same locale as the old one for pg_upgrade to work. Make sure you select
""German_Switzerland.1252" in the PostgreSQL 13 installer.

Or you can re-initialize the datadir after installing PostgreSQL with
something like:

initdb -D "C:/Program Files/PostgreSQL/13/data"
--locale="German_Switzerland.1252"

- Heikki

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message PG Bug reporting form 2020-11-23 08:41:07 BUG #16739: Temporary files not deleting from data folder on disk
Previous Message Dilip Kumar 2020-11-23 05:21:40 Re: BUG #16643: PG13 - Logical replication - initial startup never finishes and gets stuck in startup loop