You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by "Myroslav Papirkovskyy (JIRA)" <ji...@apache.org> on 2014/04/04 17:16:15 UTC

[jira] [Resolved] (AMBARI-5344) Error with finding FK constraint

     [ https://issues.apache.org/jira/browse/AMBARI-5344?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Myroslav Papirkovskyy resolved AMBARI-5344.
-------------------------------------------

    Resolution: Fixed

Pushed to trunk

> Error with finding FK constraint
> --------------------------------
>
>                 Key: AMBARI-5344
>                 URL: https://issues.apache.org/jira/browse/AMBARI-5344
>             Project: Ambari
>          Issue Type: Bug
>          Components: controller
>    Affects Versions: 1.5.0
>            Reporter: Myroslav Papirkovskyy
>            Assignee: Myroslav Papirkovskyy
>             Fix For: 1.5.1
>
>
> *Steps*:
> - Install Ambari-1.3.2 with Oracle DB.
> - Upgrade ambari to 1.5.0
> - Run "ambari-server upgrade" command.
> Seems like check before execute doesn't work for Oracle. Since we ignore failures this is not block the upgrade.
> *Exception*:
> {code}
> 16:41:36,719  WARN [main] DBAccessorImpl:416 - Error executing query: ALTER TABLE clusterconfigmapping ADD CONSTRAINT FK_clustercfgmap_cluster_id FOREIGN KEY (cluster_id) REFERENCES clusters (cluster_id)
> java.sql.SQLSyntaxErrorException: ORA-02275: such a referential constraint already exists in the table
>         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:445)
>         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396)
>         at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:879)
>         at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:450)
>         at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192)
>         at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:531)
>         at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:193)
>         at oracle.jdbc.driver.T4CStatement.executeForRows(T4CStatement.java:1033)
>         at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1329)
>         at oracle.jdbc.driver.OracleStatement.executeInternal(OracleStatement.java:1909)
>         at oracle.jdbc.driver.OracleStatement.execute(OracleStatement.java:1871)
>         at oracle.jdbc.driver.OracleStatementWrapper.execute(OracleStatementWrapper.java:318)
>         at org.apache.ambari.server.orm.DBAccessorImpl.executeQuery(DBAccessorImpl.java:413)
>         at org.apache.ambari.server.orm.DBAccessorImpl.executeQuery(DBAccessorImpl.java:399)
>         at org.apache.ambari.server.orm.DBAccessorImpl.addFKConstraint(DBAccessorImpl.java:262)
>         at org.apache.ambari.server.upgrade.UpgradeCatalog150.executeDDLUpdates(UpgradeCatalog150.java:375)
>         at org.apache.ambari.server.upgrade.AbstractUpgradeCatalog.upgradeSchema(AbstractUpgradeCatalog.java:177)
>         at org.apache.ambari.server.upgrade.SchemaUpgradeHelper.executeUpgrade(SchemaUpgradeHelper.java:174)
>         at org.apache.ambari.server.upgrade.SchemaUpgradeHelper.main(SchemaUpgradeHelper.java:234)
> 16:41:36,720  WARN [main] DBAccessorImpl:264 - Add FK constraint failed, constraintName = FK_clustercfgmap_cluster_id, tableName = clusterconfigmapping, errorCode = 2275, message = ORA-02275: such a referential constraint already exists in the table
> {code}



--
This message was sent by Atlassian JIRA
(v6.2#6252)