Bug #23388
closedServer install fails with postgresql encoding error
Description
Greetings -
Three different installs... all failed.
Attempt 1 - Debian Bullseye
Attempt 2 - Debian Bookworm
Attempt 3 - Ubuntu Jammy
What other information may I provide?
Here's a snippet of the end result (the same on each of the attempts above)...
ERROR: new encoding (UTF8) is incompatible with the encoding of the template database (SQL_ASCII) HINT: Use the same encoding as in the template database, or use template0 as template. ************************************************************************************** ERROR: rudder-webapp postinstall script failed ! Trying to recover the problem, you should check that your instance is properly working You may need to execute: apt-get install -f You should also try to manually execute: /opt/rudder/bin/rudder-upgrade Such errors should not happen, please open an issue for this problem on https://issues.rudder.io/projects/rudder/issues/new ************************************************************************************** chmod: cannot access '/var/rudder/configuration-repository/.git': No such file or directory chmod: cannot access '/var/rudder/configuration-repository/techniques': No such file or directory find: '/var/rudder/configuration-repository/.git': No such file or directory find: '/var/rudder/configuration-repository/techniques': No such file or directory
Updated by François ARMAND about 1 year ago
- Related to Bug #20937: Postgresql is not created with the UTF8 encoding added
Updated by Alexis Mousset about 1 year ago
- Category set to Packaging
- Target version set to 7.3.6
Were you trying to install a Rudder 7.3? This is definitely unexpected, and could be linked to https://issues.rudder.io/issues/20937.
Updated by Alexis Mousset about 1 year ago
According to https://stackoverflow.com/a/28131347 it seems to be linked to the system locale:
If you use Debian, when you install the postgresql package it will use your default locale to create the template1 database. If you have not configured your OS to use UTF-8 as a default locale, you will encounter this error.
What does the locale
command return on one of your systems? Did you configure a specific non-UTF8 encoding?
Updated by Alexis Mousset about 1 year ago
- Target version changed from 7.3.6 to 7.2.11
Updated by Alexis Mousset about 1 year ago
- Subject changed from new install failed to Server install fails with postgresql encoding error
Updated by Nicolas CHARLES about 1 year ago
According to https://www.postgresql.org/docs/current/manage-ag-templatedbs.html, if the database is created using template0 rather than default template1 template, then we can use the universal UTF8 encoding
Updated by François ARMAND about 1 year ago
- Status changed from New to In progress
- Assignee set to François ARMAND
Updated by François ARMAND about 1 year ago
- Status changed from In progress to Pending technical review
- Assignee changed from François ARMAND to Alexis Mousset
- Pull Request set to https://github.com/Normation/rudder-packages/pull/2807
Updated by François ARMAND about 1 year ago
PR done and validated, it should be testable in following nigthlies
Updated by Anonymous about 1 year ago
- Status changed from Pending technical review to Pending release
Applied in changeset rudder-packages|2fe9c631dfff9d5094179b330773d84a227f3998.
Updated by Marc Evans about 1 year ago
Can confirm it was this noob user's mistake - no locale's were set in each install iteration. Having set the locales, install runs quite well.
Updated by Alexis Mousset about 1 year ago
- Fix check changed from To do to Checked
Updated by Vincent MEMBRÉ about 1 year ago
- Status changed from Pending release to Released
This bug has been fixed in Rudder 7.2.11 and 7.3.7 which were released today.