Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Upgrade error "Cannot update schema"

Nerdsgrp August 3, 2020

Hello,

Upgrading from 6.10 to 7.4.3. after completing upgrade I received this error page:

Pre-upgrade validation failed. Check the Confluence application logs for more details. You'll need to fix these problems and restart Confluence before you can upgrade. Upgrade error message: Cannot update schema

 

Our database is mssql2019

 

I don't see a place for  attachments so here is a copy and paste from  from the first 50 lines or so. let me know if you need the full log. 

 

"2020-08-03 12:36:14,858 ERROR [Caesium-1-4] [migration.agent.queue.QueueBroker] error An error occurred when getting the next batch for consumer type: DATA_UPLOAD. Message: javax.persistence.PersistenceException: Failed to update database schema
com.atlassian.util.concurrent.LazyReference$InitializationException: javax.persistence.PersistenceException: Failed to update database schema
at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:149)
at com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:112)
at com.atlassian.migration.agent.store.jpa.impl.DefaultSessionFactorySupplier.get(DefaultSessionFactorySupplier.java:65)
at com.atlassian.migration.agent.store.jpa.impl.DefaultSessionFactorySupplier.get(DefaultSessionFactorySupplier.java:40)
at com.atlassian.migration.agent.store.jpa.impl.DefaultPluginTransactionTemplate.on(DefaultPluginTransactionTemplate.java:29)
at com.atlassian.migration.agent.store.tx.PluginTransactionTemplate.write(PluginTransactionTemplate.java:24)
at com.atlassian.migration.agent.queue.QueueBroker.getNextBatch(QueueBroker.java:119)
at com.atlassian.migration.agent.queue.QueueBroker.dispatchBatchToConsumer(QueueBroker.java:113)
at java.util.ArrayList.forEach(ArrayList.java:1257)
at com.atlassian.migration.agent.queue.QueueBroker.runJob(QueueBroker.java:100)
at com.atlassian.confluence.impl.schedule.caesium.JobRunnerWrapper.doRunJob(JobRunnerWrapper.java:120)
at com.atlassian.confluence.impl.schedule.caesium.JobRunnerWrapper.lambda$runJob$0(JobRunnerWrapper.java:91)
at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContextInternal(VCacheRequestContextManager.java:87)
at com.atlassian.confluence.impl.vcache.VCacheRequestContextManager.doInRequestContext(VCacheRequestContextManager.java:71)
at com.atlassian.confluence.impl.schedule.caesium.JobRunnerWrapper.runJob(JobRunnerWrapper.java:91)
at com.atlassian.scheduler.core.JobLauncher.runJob(JobLauncher.java:134)
at com.atlassian.scheduler.core.JobLauncher.launchAndBuildResponse(JobLauncher.java:106)
at com.atlassian.scheduler.core.JobLauncher.launch(JobLauncher.java:90)
at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService.launchJob(CaesiumSchedulerService.java:443)
at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService.executeLocalJob(CaesiumSchedulerService.java:410)
at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService.executeQueuedJob(CaesiumSchedulerService.java:388)
at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService$1.consume(CaesiumSchedulerService.java:285)
at com.atlassian.scheduler.caesium.impl.CaesiumSchedulerService$1.consume(CaesiumSchedulerService.java:282)
at com.atlassian.scheduler.caesium.impl.SchedulerQueueWorker.executeJob(SchedulerQueueWorker.java:65)
at com.atlassian.scheduler.caesium.impl.SchedulerQueueWorker.executeNextJob(SchedulerQueueWorker.java:59)
at com.atlassian.scheduler.caesium.impl.SchedulerQueueWorker.run(SchedulerQueueWorker.java:34)
at java.lang.Thread.run(Thread.java:748)
Caused by: javax.persistence.PersistenceException: Failed to update database schema
at com.atlassian.migration.agent.store.jpa.impl.LiquibaseSchemaUpgrader.upgrade(LiquibaseSchemaUpgrader.java:35)
at com.atlassian.migration.agent.store.jpa.impl.DefaultSessionFactorySupplier.buildSessionFactory(DefaultSessionFactorySupplier.java:70)
at com.atlassian.util.concurrent.Lazy$Strong.create(Lazy.java:85)
at com.atlassian.util.concurrent.LazyReference$Sync.run(LazyReference.java:325)
at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:143)
at com.atlassian.util.concurrent.LazyReference.get(LazyReference.java:112)
at com.atlassian.migration.agent.store.jpa.impl.DefaultSessionFactorySupplier.get(DefaultSessionFactorySupplier.java:65)
at com.atlassian.migration.agent.store.jpa.impl.DefaultSessionFactorySupplier.get(DefaultSessionFactorySupplier.java:40)
at com.atlassian.migration.agent.store.jpa.impl.DefaultPluginTransactionTemplate.on(DefaultPluginTransactionTemplate.java:29)
at com.atlassian.migration.agent.store.tx.PluginTransactionTemplate.read(PluginTransactionTemplate.java:16)
at com.atlassian.migration.agent.service.impl.DefaultStatisticsService.loadSpaceStatistics(DefaultStatisticsService.java:138)
at com.atlassian.migration.agent.service.impl.DefaultStatisticsService.calculateServerStats(DefaultStatisticsService.java:167)
at com.atlassian.migration.agent.service.impl.SingleJobExecutor.lambda$execute$0(SingleJobExecutor.java:33)
at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1590)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
... 1 more
Caused by: liquibase.exception.MigrationFailedException: Migration failed for change set META-INF/db-changelog/5-attachment-migration-version.xml::5-attachment-migration-version-drop-index::MPT:
Reason:
META-INF/db-changelog/master.xml : Index Exists Precondition: MIG_ATTACH_SITE_PROGRESS_IDX on MIG_ATTACHMENT : The database name component of the object qualifier must be the name of the current database."

 

 

Thanks!

2 answers

1 accepted

1 vote
Answer accepted
Shannon S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 5, 2020

Hello,

Thank you for raising this with us.

Supported databases

Not that I believe this to be the exact cause of your error, but I want to point out that MS SQL 2019 is not a supported database for the current versions of Confluence.

See Supported Platforms for the list of supported databases. As far as Microsoft SQL goes, we support versions 2016, 2017, and Azure SQL. Note that Express versions are also not supported.

There's a feature request below to introduce SQL 2019 support to Confluence:

In the meantime, you'll need to get moved over to a supported database version, which you can do following the Migrating to Another Database. You'll want to make sure to get on a supported database, because there can be other issues that you'll run into if not. 

Regarding your error message

There appears to be an article in our documentation that could help you with this issue:

If the migration to a supported database doesn't automatically fix the issue, I recommend reviewing this article carefully in order to correct the issue.

Let me know if you have any trouble with that!

Take care,

Shannon

Nerdsgrp August 5, 2020

Hi Shannon, 

Thanks for your reply.

I double checked and it seems we are running mssql 2017 and not 2019.

I will take a look at the article you sent me!

 

EDIT:  applied fix from above article and upgraded. Worked like a charm! 

 

Thanks, 

Matthew

Like Deleted user likes this
Shannon S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
August 6, 2020

Hi Matthew, 

Happy to hear that you are indeed on a supported MS SQL version, and that the recommended fix from the article worked out for you!

Take care, and have a pleasant rest of your week.

Shannon

Like Deleted user likes this
0 votes
戴宝清 September 8, 2023

怎么秀'f禅姆禅泽

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
AUG Leaders

Atlassian Community Events