Postgres 17 cluster is in Windows server in Estonian locale. Databases are defined like
CREATE DATABASE mydb
WITH
OWNER = mydb_owner
ENCODING = 'UTF8'
LC_COLLATE = 'et-EE'
LC_CTYPE = 'et-EE'
LOCALE_PROVIDER = 'libc'
TABLESPACE = pg_default
CONNECTION LIMIT = -1
IS_TEMPLATE = False;
Trying to move this to Postgres 18 running in Debian
pg_dumpall --clean -h windowsserver.com -U postgres | psql --echo-errors -h localhost -U postgres
Throws
ERROR: invalid LC_COLLATE locale name: "et-EE"
STATEMENT: CREATE DATABASE template1 WITH TEMPLATE = template0 ENCODING = 'UTF8'
LOCALE_PROVIDER = libc LOCALE = 'et-EE';
locale -a shows that Estonian locale is present:
C
C.utf8
en_US.utf8
et_EE.utf8
POSIX
How to move cluster to Postgres 18 ?
sedcommand to add to pipe to perform locale substitution? There is only single database which needs to be moved.pg_database_sizeshows its size64GB.--schema-only Dump only the object definitions (schema), not data.. That should be fairly small and you can directly edit the CREATE DATABASE section. Then--data-only Dump only the data, not the schema (data definitions) or statistics.to transfer the data.