Page MenuHomePhabricator

Maps-test was created with incorrect initial encoding
Closed, ResolvedPublic

Description

Running psql -l shows that maps-test* postgres DBs were created with SQL_ASCII, whereas all our production servers have it set to UTF8.

Event Timeline

Yurik created this task.Oct 14 2016, 3:34 AM
Restricted Application added a project: Discovery. · View Herald TranscriptOct 14 2016, 3:34 AM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Gehel added a comment.Oct 17 2016, 7:54 AM

Strange thing is that other servers have been reimaged recently and database were created with UTF-8 encoding. There is probably a missing dependency somewhere in Puppet. I'm having a look...

Gehel added a comment.Oct 17 2016, 5:00 PM

The issue seems to be that when puppet is run manually, the $LANG variable is set, which is used by initdb to guess at the correct encoding. When puppet is run non interactively, which is the case during re-image, encoding falls back to SQL_ASCII. Setting the encoding / locale explicitly should fix that.

Gehel moved this task from Backlog to In progress on the Maps-Sprint board.Oct 19 2016, 6:51 PM
Gehel closed this task as Resolved.Oct 25 2016, 12:37 PM

Puppet now explicitly sets the locale to use. maps-test cluster has been reimaged with the new puppet code and encoding is now UTF-8.