You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@bigtop.apache.org by "Masatake Iwasaki (Jira)" <ji...@apache.org> on 2020/09/29 11:49:02 UTC

[jira] [Commented] (BIGTOP-3422) Fix ambari-server setup failure due to PostgreSQL initdb error

    [ https://issues.apache.org/jira/browse/BIGTOP-3422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17203871#comment-17203871 ] 

Masatake Iwasaki commented on BIGTOP-3422:
------------------------------------------

The cause turned out to be the locale.
{noformat}
[root@e175411847c9 /]# cat /var/lib/pgsql/initdb_postgresql.log
The files belonging to this database system will be owned by user "postgres".
This user must also own the server process.

initdb: invalid locale settings; check LANG and LC_* environment variables
{noformat}

{{--no-locale}} on initdb should be the fix. The cmdline is not configurable in Ambari. Setting environment variable in puppet manifest might be an option.
{noformat}
[root@e175411847c9 /]# PGSETUP_INITDB_OPTIONS="--no-locale" /usr/bin/postgresql-setup initdb
WARNING: using obsoleted argument syntax, try --help
WARNING: arguments transformed to: postgresql-setup --initdb --unit postgresql
 * Initializing database in '/var/lib/pgsql/data'
 * Initialized, logs are in /var/lib/pgsql/initdb_postgresql.log
{noformat}

> Fix ambari-server setup failure due to PostgreSQL initdb error
> --------------------------------------------------------------
>
>                 Key: BIGTOP-3422
>                 URL: https://issues.apache.org/jira/browse/BIGTOP-3422
>             Project: Bigtop
>          Issue Type: Bug
>          Components: deployment
>            Reporter: Masatake Iwasaki
>            Priority: Major
>
> {{ambari-server setup}} failed on CentOS 8 due to error on starting PostgreSQL.
> {noformat}
> Notice: /Stage[main]/Ambari::Server/Exec[server setup]/returns: Configuring ambari database...
> Notice: /Stage[main]/Ambari::Server/Exec[server setup]/returns: Checking PostgreSQL...
> Notice: /Stage[main]/Ambari::Server/Exec[server setup]/returns: Running initdb: This may take up to a minute.
> Notice: /Stage[main]/Ambari::Server/Exec[server setup]/returns: About to start PostgreSQL
> Notice: /Stage[main]/Ambari::Server/Exec[server setup]/returns: ERROR: Exiting with exit code 3.
> Notice: /Stage[main]/Ambari::Server/Exec[server setup]/returns: REASON: Unable to start PostgreSQL server. Exiting
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)