You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by Andrew Onischuk <ao...@hortonworks.com> on 2015/03/27 17:37:10 UTC

Review Request 32578: Ambari-server does not start with Postgres_External

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/32578/
-----------------------------------------------------------

Review request for Ambari and Myroslav Papirkovskyy.


Bugs: AMBARI-10246
    https://issues.apache.org/jira/browse/AMBARI-10246


Repository: ambari


Description
-------

1. Setup ambari-server with postgres_external DB
  2. There is a warning for postgres embedded, setup perfomes successfully, ambari-server does not start.  
**WARNING: Before starting Ambari Server, you must run the following DDL against the database to create the schema: /var/lib/ambari-server/resources/Ambari-DDL-Postgres-EMBEDDED-CREATE.sql**  
The job example : <http://linux-jenkins.qe.hortonworks.com:8080/job/Run-
Ambari-Setup/1385/console>  
Pay attention to these errors while filling DB:

    
        
    BEGIN
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:893: ERROR:  duplicate key value violates unique constraint "ambari_sequences_pkey"
    DETAIL:  Key (sequence_name)=(upgrade_group_id_seq) already exists.
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:900: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:903: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:908: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:911: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:914: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:923: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:926: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:929: ERROR:  current transaction is aborted, commands ignored until end of transaction block
    ROLLBACK
    

The db output : <http://pastebin.com/9ntw9CC3>

    
        
    ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -q -i /grid/0/jenkins/workspace/Run-Ambari-Setup/build-utils/openstack-utils/accounts/hw-qe-keypair.pem root@172.22.71.84 "ambari-server setup --database=postgres --databasehost=us-rare-mon-rhe6-5013-re-4.novalocal --databaseport=5432 --databasename=ambari --databaseusername=ambari --databasepassword=bigdata --java-home=/usr/lib/jvm/java-1.7.0-openjdk.x86_64 -s"
    Using python  /usr/bin/python2.6
    Setup ambari-server
    Checking SELinux...
    SELinux status is 'enabled'
    SELinux mode is 'enforcing'
    Temporarily disabling SELinux
    WARNING: SELinux is set to 'permissive' mode and temporarily disabled.
    OK to continue [y/n] (y)? 
    Customize user account for ambari-server daemon [y/n] (n)? 
    Adjusting ambari-server permissions and ownership...
    Checking firewall status...
    Checking JDK...
    WARNING: JAVA_HOME /usr/lib/jvm/java-1.7.0-openjdk.x86_64 must be valid on ALL hosts
    WARNING: JCE Policy files are required for configuring Kerberos security. If you plan to use Kerberos,please make sure JCE Unlimited Strength Jurisdiction Policy Files are valid on all hosts.
    Completing setup...
    Configuring database...
    Configuring database...
    Configuring ambari database...
    Configuring remote database connection properties...
    WARNING: Before starting Ambari Server, you must run the following DDL against the database to create the schema: /var/lib/ambari-server/resources/Ambari-DDL-Postgres-EMBEDDED-CREATE.sql
    Proceed with configuring remote database connection properties [y/n] (y)? 
    Extracting system views...
    .ambari-admin-2.1.0.19.jar
    ..
    Adjusting ambari-server permissions and ownership...
    Ambari Server 'setup' completed successfully.
    
    
        
    Starting ambari-server
    Ambari Server running with administrator privileges.
    Organizing resource files at /var/lib/ambari-server/resources...
    Server PID at: /var/run/ambari-server/ambari-server.pid
    Server out at: /var/log/ambari-server/ambari-server.out
    Server log at: /var/log/ambari-server/ambari-server.log
    Waiting for server start....................
    ERROR: Exiting with exit code -1.


Diffs
-----

  ambari-server/src/main/resources/Ambari-DDL-Postgres-CREATE.sql cd4427f 

Diff: https://reviews.apache.org/r/32578/diff/


Testing
-------

mvn clean test


Thanks,

Andrew Onischuk


Re: Review Request 32578: Ambari-server does not start with Postgres_External

Posted by Myroslav Papirkovskyy <mp...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/32578/#review78072
-----------------------------------------------------------

Ship it!


Ship It!

- Myroslav Papirkovskyy


On Березень 27, 2015, 6:37 після полудня, Andrew Onischuk wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/32578/
> -----------------------------------------------------------
> 
> (Updated Березень 27, 2015, 6:37 після полудня)
> 
> 
> Review request for Ambari and Myroslav Papirkovskyy.
> 
> 
> Bugs: AMBARI-10246
>     https://issues.apache.org/jira/browse/AMBARI-10246
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> 1. Setup ambari-server with postgres_external DB
>   2. There is a warning for postgres embedded, setup perfomes successfully, ambari-server does not start.  
> **WARNING: Before starting Ambari Server, you must run the following DDL against the database to create the schema: /var/lib/ambari-server/resources/Ambari-DDL-Postgres-EMBEDDED-CREATE.sql**  
> The job example : <http://linux-jenkins.qe.hortonworks.com:8080/job/Run-
> Ambari-Setup/1385/console>  
> Pay attention to these errors while filling DB:
> 
>     
>         
>     BEGIN
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:893: ERROR:  duplicate key value violates unique constraint "ambari_sequences_pkey"
>     DETAIL:  Key (sequence_name)=(upgrade_group_id_seq) already exists.
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:900: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:903: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:908: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:911: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:914: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:923: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:926: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     psql:/tmp/Ambari-DDL-Postgres-CREATE.sql:929: ERROR:  current transaction is aborted, commands ignored until end of transaction block
>     ROLLBACK
>     
> 
> The db output : <http://pastebin.com/9ntw9CC3>
> 
>     
>         
>     ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -q -i /grid/0/jenkins/workspace/Run-Ambari-Setup/build-utils/openstack-utils/accounts/hw-qe-keypair.pem root@172.22.71.84 "ambari-server setup --database=postgres --databasehost=us-rare-mon-rhe6-5013-re-4.novalocal --databaseport=5432 --databasename=ambari --databaseusername=ambari --databasepassword=bigdata --java-home=/usr/lib/jvm/java-1.7.0-openjdk.x86_64 -s"
>     Using python  /usr/bin/python2.6
>     Setup ambari-server
>     Checking SELinux...
>     SELinux status is 'enabled'
>     SELinux mode is 'enforcing'
>     Temporarily disabling SELinux
>     WARNING: SELinux is set to 'permissive' mode and temporarily disabled.
>     OK to continue [y/n] (y)? 
>     Customize user account for ambari-server daemon [y/n] (n)? 
>     Adjusting ambari-server permissions and ownership...
>     Checking firewall status...
>     Checking JDK...
>     WARNING: JAVA_HOME /usr/lib/jvm/java-1.7.0-openjdk.x86_64 must be valid on ALL hosts
>     WARNING: JCE Policy files are required for configuring Kerberos security. If you plan to use Kerberos,please make sure JCE Unlimited Strength Jurisdiction Policy Files are valid on all hosts.
>     Completing setup...
>     Configuring database...
>     Configuring database...
>     Configuring ambari database...
>     Configuring remote database connection properties...
>     WARNING: Before starting Ambari Server, you must run the following DDL against the database to create the schema: /var/lib/ambari-server/resources/Ambari-DDL-Postgres-EMBEDDED-CREATE.sql
>     Proceed with configuring remote database connection properties [y/n] (y)? 
>     Extracting system views...
>     .ambari-admin-2.1.0.19.jar
>     ..
>     Adjusting ambari-server permissions and ownership...
>     Ambari Server 'setup' completed successfully.
>     
>     
>         
>     Starting ambari-server
>     Ambari Server running with administrator privileges.
>     Organizing resource files at /var/lib/ambari-server/resources...
>     Server PID at: /var/run/ambari-server/ambari-server.pid
>     Server out at: /var/log/ambari-server/ambari-server.out
>     Server log at: /var/log/ambari-server/ambari-server.log
>     Waiting for server start....................
>     ERROR: Exiting with exit code -1.
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/resources/Ambari-DDL-Postgres-CREATE.sql cd4427f 
> 
> Diff: https://reviews.apache.org/r/32578/diff/
> 
> 
> Testing
> -------
> 
> mvn clean test
> 
> 
> Thanks,
> 
> Andrew Onischuk
> 
>