ALERT: Some images may not load properly within the Knowledge Base Article. If you see a broken image, please right-click and select 'Open image in a new tab'. We apologize for this inconvenience.
Database errors post Upgrade from 10.5.2.15 to 10.7.0.45
Article ID: 108028
CA Application Performance Management Agent (APM / Wily / Introscope)INTROSCOPE
After restoring and upgrading the cemdb to 10.7.0.45, I upgraded the EM to the same version and started it. However, the EM failed to start with the following error:
[ERROR] [main] [Apm.Data.Model] APM Database is not reachable. Please check the connectivity... org.springframework.dao.InvalidDataAccessResourceUsageException: could not execute query; SQL [select this_.id as id5_0_, this_.name as name5_0_, this_.creation_date as creation3_5_0_, this_.update_date as update4_5_0_, this_.user_name as user5_5_0_ from apm_vertex_type this_ where this_.name=?]; nested exception is org.hibernate.exception.SQLGrammarException: could not execute query at org.springframework.orm.hibernate3.SessionFactoryUtils.convertHibernateAccessException(SessionFactoryUtils.java:635) at org.springframework.orm.hibernate3.HibernateAccessor.convertHibernateAccessException(HibernateAccessor.java:412) . . Caused by: org.hibernate.exception.SQLGrammarException: could not execute query at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67) . . ... 73 more Caused by: org.postgresql.util.PSQLException: ERROR: relation "apm_vertex_type" does not exist Position: 161 at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2157) at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1886) . . ... 81 more
Upon further troubleshooting, we found out that the cemdb was actually empty. The restore process did not complete properly.
CA Application Performance Management 10.7.0.45
Re-run the restore process with the 10.7 dbrestore-postgres.sh script, which restores and upgrade the schemas to 10.7 successfully.