Failed to start AIQUM services after update due to database schema was not updated
Applies to
- Active IQ Unified Manager (AIQUM)9.6+
- OnCommand Unified Manager (OCUM) 9.5 and below
- All OS platforms
Issue
- After updating AIQUM the AIQUM services fail.
- The messages in
/var/log/ocum/
ocumserver.log
suggest that the database was not updated:
2023-08-31 11:07:17,734 ERROR [oncommand] [ServerService Thread Pool -- 118] [o.s.web.context.ContextLoader] Context initialization failed
org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSourceInformationServiceImpl': Unsatisfied dependency expressed through field 'dataSourceCacheService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSourceCacheService': Unsatisfied dependency expressed through field 'ontapConnectionInfoProvider'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSourceManager': Unsatisfied dependency expressed through field 'dataSourceEntityManager'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSourceEntityManager': Unsatisfied dependency expressed through field 'session'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'hibernateSessionProxyFactoryBean': Unsatisfied dependency expressed through field 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'migrationVersionVerifier': Invocation of init method failed; nested exception is java.lang.IllegalStateException: The database schema is not up to date. Run the 'db update' tool to bring the schema up to date.
- There is a database setup error in
/var/log/ocum/dbsetup.log
2023-08-31 11:05:35,721 DEBUG [main] [c.n.dfm.migrations.DbMain] Database setup error
org.springframework.dao.TransientDataAccessResourceException: StatementCallback; SQL [DROP DATABASE IF EXISTS test;]; (conn=16) Schema 'test' does not exist, but schema directory './test/' was found. This must be resolved manually (e.g. by moving the schema directory to another location).; nested exception is java.sql.SQLTransientConnectionException: (conn=16) Schema 'test' does not exist, but schema directory './test/' was found. This must be resolved manually (e.g. by moving the schema directory to another location).