pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedDefault Sort order Problem - Newbie ;-)
3+ messages / 2 participants
[nested] [flat]
* Default Sort order Problem - Newbie ;-)
@ 2022-11-23 02:23 Franz Xaver <drummelbummel@hotmail.com>
2022-11-23 07:58 ` Re: Default Sort order Problem - Newbie ;-) Holger Jakobs <holger@jakobs.com>
0 siblings, 1 reply; 3+ messages in thread
From: Franz Xaver @ 2022-11-23 02:23 UTC (permalink / raw)
To: pgsql-admin@lists.postgresql.org <pgsql-admin@lists.postgresql.org>
Hello,
i am updating GVM on an existing System (Kali Linux). There’s a strange Problem i can not solve myself and even Google search does not bring me further.
There’s two clusters and i had been able to switch the Default to 15
C:\home\kali> pg_lsclusters
Ver Cluster Port Status Owner Data directory Log file
14 main 5433 online postgres /var/lib/postgresql/14/main /var/log/postgresql/postgresql-14-main.log
15 main 5432 online postgres /var/lib/postgresql/15/main /var/log/postgresql/postgresql-15-main.log
But the database can not be created due to error:
WARNUNG: Version von Sortierfolge für Datenbank »postgres« stimmt nicht überein
DETAIL: Die Datenbank wurde mit Sortierfolgenversion 2.35 erzeugt, aber das Betriebssystem hat Version 2.36.
TIP: Bauen Sie alle Objekte in dieser Datenbank, die die Standardsortierfolge verwenden, neu und führen Sie ALTER DATABASE postgres REFRESH COLLATION VERSION aus, oder bauen Sie PostgreSQL mit der richtigen Bibliotheksversion.
psql (15.1 (Debian 15.1-1))
„Sortierfolgenversion“ seems to be „sort order“ in english?
I tried the given command with no success. The database can not be created:
C:\home\kali> sudo runuser -u postgres -- /usr/share/gvm/create-postgresql-database 1 ⨯
WARNUNG: Version von Sortierfolge für Datenbank »postgres« stimmt nicht überein
DETAIL: Die Datenbank wurde mit Sortierfolgenversion 2.35 erzeugt, aber das Betriebssystem hat Version 2.36.
TIP: Bauen Sie alle Objekte in dieser Datenbank, die die Standardsortierfolge verwenden, neu und führen Sie ALTER DATABASE postgres REFRESH COLLATION VERSION aus, oder bauen Sie PostgreSQL mit der richtigen Bibliotheksversion.
[i] User _gvm already exists in PostgreSQL
WARNUNG: Version von Sortierfolge für Datenbank »postgres« stimmt nicht überein
DETAIL: Die Datenbank wurde mit Sortierfolgenversion 2.35 erzeugt, aber das Betriebssystem hat Version 2.36.
TIP: Bauen Sie alle Objekte in dieser Datenbank, die die Standardsortierfolge verwenden, neu und führen Sie ALTER DATABASE postgres REFRESH COLLATION VERSION aus, oder bauen Sie PostgreSQL mit der richtigen Bibliotheksversion.
Unfortunately changing locales to en did not Change the language of the Messages but hopfully it is easy for an exper to find the cause of my Problems.
What Needs to be done to fix this issue?
Sorry – yes i am a newbie with postgress.
Thx POW
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Default Sort order Problem - Newbie ;-)
2022-11-23 02:23 Default Sort order Problem - Newbie ;-) Franz Xaver <drummelbummel@hotmail.com>
@ 2022-11-23 07:58 ` Holger Jakobs <holger@jakobs.com>
0 siblings, 0 replies; 3+ messages in thread
From: Holger Jakobs @ 2022-11-23 07:58 UTC (permalink / raw)
To: pgsql-admin@lists.postgresql.org
Am 23.11.22 um 03:23 schrieb Franz Xaver:
>
> Hello,
>
> i am updating GVM on an existing System (Kali Linux). There’s a
> strange Problem i can not solve myself and even Google search does not
> bring me further.
>
What is GVM? Obviously nothing Postgres related.
> There’s two clusters and i had been able to switch the Default to 15
>
> C:\home\kali> pg_lsclusters
>
> Ver Cluster Port Status Owner Data directory Log file
>
> 14 main 5433 online postgres /var/lib/postgresql/14/main
> /var/log/postgresql/postgresql-14-main.log
>
> 15 main 5432 online postgres /var/lib/postgresql/15/main
> /var/log/postgresql/postgresql-15-main.log
>
> But the database can not be created due to error:
>
> WARNUNG: Version von Sortierfolge für Datenbank »postgres« stimmt
> nicht überein
>
> DETAIL: Die Datenbank wurde mit Sortierfolgenversion 2.35 erzeugt,
> aber das Betriebssystem hat Version 2.36.
>
> TIP: Bauen Sie alle Objekte in dieser Datenbank, die die
> Standardsortierfolge verwenden, neu und führen Sie ALTER DATABASE
> postgres REFRESH COLLATION VERSION aus, oder bauen Sie PostgreSQL mit
> der richtigen Bibliotheksversion.
>
> psql (15.1 (Debian 15.1-1))
>
You wrote "But the database can not be created due to error".
It's warning, not an error. It appears when STARTING the database server
(not creating). The message says that the database WAS created earlier
with a different version of the sorting library.
> „Sortierfolgenversion“ seems to be „sort order“ in english?
>
> I tried the given command with no success. The database can not be
> created:
>
> C:\home\kali> sudo runuser -u postgres --
> /usr/share/gvm/create-postgresql-database 1 ⨯
>
> WARNUNG: Version von Sortierfolge für Datenbank »postgres« stimmt
> nicht überein
>
> DETAIL: Die Datenbank wurde mit Sortierfolgenversion 2.35 erzeugt,
> aber das Betriebssystem hat Version 2.36.
>
> TIP: Bauen Sie alle Objekte in dieser Datenbank, die die
> Standardsortierfolge verwenden, neu und führen Sie ALTER DATABASE
> postgres REFRESH COLLATION VERSION aus, oder bauen Sie PostgreSQL mit
> der richtigen Bibliotheksversion.
>
> [i] User _gvm already exists in PostgreSQL
>
> WARNUNG: Version von Sortierfolge für Datenbank »postgres« stimmt
> nicht überein
>
> DETAIL: Die Datenbank wurde mit Sortierfolgenversion 2.35 erzeugt,
> aber das Betriebssystem hat Version 2.36.
>
> TIP: Bauen Sie alle Objekte in dieser Datenbank, die die
> Standardsortierfolge verwenden, neu und führen Sie ALTER DATABASE
> postgres REFRESH COLLATION VERSION aus, oder bauen Sie PostgreSQL mit
> der richtigen Bibliotheksversion.
>
> Unfortunately changing locales to en did not Change the language of
> the Messages but hopfully it is easy for an exper to find the cause of
> my Problems.
>
Have you tried the command ALTER DATABASE ... REFRESH COLLATION VERSION
for all databases in your cluster? That was the hint in the warning.
>
> What Needs to be done to fix this issue?
>
> Sorry – yes i am a newbie with postgress.
>
> Thx POW
>
If you ignore the warning, the database will still work, but indexes
over text values won't find all entries. Numbers and dates are not affected.
Re-Indexin everything may also help.
Viele Grüße
Holger
--
Holger Jakobs, Bergisch Gladbach, Tel. +49-178-9759012
Attachments:
OpenPGP_signature (application/pgp-signature, 202B) download
^ permalink raw reply [nested|flat] 3+ messages in thread
* Default Sort order Problem - Newbie ;-)
@ 2022-11-23 11:44 Franz Xaver <drummelbummel@hotmail.com>
0 siblings, 0 replies; 3+ messages in thread
From: Franz Xaver @ 2022-11-23 11:44 UTC (permalink / raw)
To: pgsql-admin@lists.postgresql.org <pgsql-admin@lists.postgresql.org>
Here’s what i did to solve the Problem:
sudo -u postgres psql postgres
postgres=> \list
List of databases
Name | Owner | Encoding | Collate | Ctype | ICU Locale | Locale Provider | Access privileges
-----------+----------+----------+-------------+-------------+------------+-----------------+-----------------------
postgres | postgres | UTF8 | de_DE.UTF-8 | de_DE.UTF-8 | | libc |
template0 | postgres | UTF8 | de_DE.UTF-8 | de_DE.UTF-8 | | libc | =c/postgres +
| | | | | | | postgres=CTc/postgres
template1 | postgres | UTF8 | de_DE.UTF-8 | de_DE.UTF-8 | | libc | =c/postgres +
| | | | | | | postgres=CTc/postgres
postgres=# ALTER DATABASE postgres REFRESH COLLATION VERSION;
HINWEIS: Version wird von 2.35 in 2.36 geändert
ALTER DATABASE
postgres=# ALTER DATABASE template0 REFRESH COLLATION VERSION;
FEHLER: invalid collation version change
postgres=# ALTER DATABASE template1 REFRESH COLLATION VERSION;
HINWEIS: Version wird von 2.35 in 2.36 geändert
ALTER DATABASE
postgres=# exit
What was the error?
I did not work on the right database.
Thx again for bringing me on the Right path.
PWO
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2022-11-23 11:44 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2022-11-23 02:23 Default Sort order Problem - Newbie ;-) Franz Xaver <drummelbummel@hotmail.com>
2022-11-23 07:58 ` Holger Jakobs <holger@jakobs.com>
2022-11-23 11:44 Default Sort order Problem - Newbie ;-) Franz Xaver <drummelbummel@hotmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox