[ https://issues.apache.org/jira/browse/AMBARI-23129?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Robert Levas updated AMBARI-23129: ---------------------------------- Resolution: Fixed Status: Resolved (was: Patch Available) > Multiple issues while executing Ambari server upgrade to Ambari 2.7.0 > --------------------------------------------------------------------- > > Key: AMBARI-23129 > URL: https://issues.apache.org/jira/browse/AMBARI-23129 > Project: Ambari > Issue Type: Bug > Components: ambari-server > Affects Versions: 2.7.0 > Reporter: Robert Levas > Assignee: Robert Levas > Priority: Critical > Labels: pull-request-available > Fix For: 2.7.0 > > Time Spent: 1h 50m > Remaining Estimate: 0h > > *1. An NPE is thrown will initializing the Ambari server upgrade catalog* > {code:title=com.google.inject.persist.jpa.JpaPersistService#begin} > public void begin() { > Preconditions.checkState(null == this.entityManager.get(), "Work > already begun on this thread. Looks like you have called UnitOfWork.begin() > twice without a balancing call to end() in between."); > this.entityManager.set(this.emFactory.createEntityManager()); > } > {code} > {{this.emFactory}} is {{null}}. > *Cause* > {{com.google.inject.persist.jpa.JpaPersistService#start()}} was not called > before {{com.google.inject.persist.jpa.JpaPersistService#begin}} to do order > of operations in > {{org.apache.ambari.server.upgrade.SchemaUpgradeHelper#main}}. > *Solution* > Ensure {{com.google.inject.persist.jpa.JpaPersistService#start()}} is being > called before {{com.google.inject.persist.jpa.JpaPersistService#begin}} in > {{org.apache.ambari.server.upgrade.SchemaUpgradeHelper#main}}. > ----- > *2. Missing repo_os, repo_definition, and repo_tags tables* > The {{repo_os}}, {{repo_definition}}, and {{repo_tags}} tables were never > added to the UpgradeCatalog implementation. The migration logic is also > needed. > *Solution* > Add the missing tables and logic while executing > {{org.apache.ambari.server.upgrade.UpgradeCatalog270#executeDDLUpdates}}. > ----- > *3. Entity classes are initialized before the schema of the underlying > database is updated* > *Solution* > Notify relevant classes that the persistence infrastructure is ready after > DDL updates have been applied. > The {{org.apache.ambari.server.events.publishers.AmbariEventPublisher}} is to > be used for issuing a > {{org.apache.ambari.server.events.JpaInitializedEvent}}. > ----- > *4. JVM does not exit after performing upgrade* > After executing {{ambari-server upgrade}}, the JVM process hangs and does not > exit. According to the logs, no errors have occurred. > *Cause* > The cause of this is several non-daemon threads not being shutdown by Ambari > code. > *Solution* > Change relevant non-daemon threads to daemon threads and ensure any thread > polls are not forcing one thread to be alive at all times. -- This message was sent by Atlassian JIRA (v7.6.3#76005)