Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-58052

post-upgrade health-check throws false warning: The database collation 'en_US.utf8' is not supported by Confluence. You need to use 'utf-8'.

    XMLWordPrintable

Details

    Description

      Bug Summary:

      post-upgrade health-check throws false warning: The database collation 'en_US.utf8' is not supported by Confluence. You need to use 'utf-8'.

      Environment:

      Confluence 6.4 -> upgraded to 6.14.2, postgresql 9.6

      Steps to replicate

      1. Create postgres database with en_US.utf8 collation/cset:
        CREATE DATABASE test_db with ENCODING 'UTF-8' LC_COLLATE 'en_US.utf8' LC_CTYPE 'en_US.utf8' TEMPLATE template0 OWNER postgres;
        
      1. Create new Confluence environment (using the oldest supported version of the installer), use database created in previous step
      2. Download latest Confluence installer file, proceed with upgrading existing environment
      3. Start Confluence after the upgrade

      Expected results

      Confluence starts without any issues

      Actual results

      Following warning is displayed during the startup:

      We discovered a problem while preparing to start Confluence. If you're a Confluence admin, you can either fix this problem now or ignore it, and start Confluence anyway.
      Database: The database collation 'en_US.utf8' is not supported by Confluence. You need to use 'utf-8'.
      

      Notes

      This occurs because the health check verifies against all utf-8 collations, and does not include utf8. utf8 is a supported collation, we are incorrectly reporting this as a failure.

      Workaround

      If using Docker, the initdb args can be overridden by setting POSTGRES_INITDB_ARGS to the below as per the example (this is using Kitematic).

      --encoding=UTF8 --lc-collate='en_US.UTF-8' --lc-ctype='en_US.UTF-8'
      

      It is safe to ignore the health check failure now and continue - it will only appear on upgrade.

      Attachments

        Issue Links

          Activity

            People

              jmoynihan Jamie (Inactive)
              gkowalczyk GMK
              Votes:
              28 Vote for this issue
              Watchers:
              36 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: