ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hadoop QA (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (AMBARI-10209) ClusterHostMapping table prevents cluster deployment, missing host_id column
Date Wed, 25 Mar 2015 18:39:55 GMT

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

Hadoop QA commented on AMBARI-10209:
------------------------------------

{color:red}-1 overall{color}.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12707269/AMBARI-10209.patch
  against trunk revision .

    {color:red}-1 patch{color}.  The patch command could not apply the patch.

Console output: https://builds.apache.org/job/Ambari-trunk-test-patch/2141//console

This message is automatically generated.

> ClusterHostMapping table prevents cluster deployment, missing host_id column
> ----------------------------------------------------------------------------
>
>                 Key: AMBARI-10209
>                 URL: https://issues.apache.org/jira/browse/AMBARI-10209
>             Project: Ambari
>          Issue Type: Bug
>          Components: ambari-server
>    Affects Versions: 2.1.0
>            Reporter: Alejandro Fernandez
>            Assignee: Alejandro Fernandez
>            Priority: Critical
>             Fix For: 2.1.0
>
>         Attachments: AMBARI-10209.patch
>
>
> When deploying a new cluster, the embedded Postgres SQL file has incorrect columns for
the ClusterHostMapping table.
> {code}
> psql:/Users/*/src/hwx/ambari/ambari-server/src/main/resources/Ambari-DDL-Postgres-EMBEDDED-CREATE.sql:652:
ERROR:  column "host_id" referenced in foreign key constraint does not exist
> {code}
> {code:title=During deployment...}
> [3/25/15, 1:53:28 PM] Internal Exception: org.postgresql.util.PSQLException: ERROR: column
t0.host_id does not exist
> [3/25/15, 1:54:00 PM] Query: ReadAllQuery(name="hostEntities" referenceClass=HostEntity
sql="SELECT t1.id, t1.cpu_count, t1.cpu_info, t1.discovery_status, t1.host_attributes, t1.host_name,
t1.ipv4, t1.ipv6, t1.last_registration_time, t1.os_arch, t1.os_info, t1.os_type, t1.ph_cpu_count,
t1.public_host_name, t1.rack_info, t1.total_mem FROM ClusterHostMapping t0, hosts t1 WHERE
((t0.cluster_id = ?) AND (t1.id = t0.host_id))")
> {code}
> It looks like the host_id is commented out of the table. Correcting this causes:
> {code}
> Caused by: org.postgresql.util.PSQLException: ERROR: null value in column "host_name"
violates not-null constraint
> {code}
> It looks like the correct table declaration is:
> {code}
> CREATE TABLE ambari.ClusterHostMapping (
>   cluster_id BIGINT NOT NULL,
>   host_id BIGINT NOT NULL,
>   PRIMARY KEY (cluster_id, host_id));
> GRANT ALL PRIVILEGES ON TABLE ambari.ClusterHostMapping TO :username;
> {code}
> It looks like all of the SQL files have this problem...



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message