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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,464,095
Community Members
 
Community Events
176
Community Groups

Confluence Cloud Migration Assistant - enable fails

Confluence (on-prem) Server - 7.2.0

Cloud Migration Assistant for Confluence - 3.0.2

Plugin installs OK.

Plugin fails to enable.

Cause:

org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getInitialState' in class com.atlassian.migration.agent.web.AppAction threw exception com.atlassian.util.concurrent.LazyReference$InitializationException: javax.persistence.PersistenceException: Failed to update database schema at /templates/app.vm[line 21, column 44]
    at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:228)

caused by: com.atlassian.util.concurrent.LazyReference$InitializationException: javax.persistence.PersistenceException: Failed to update database schema
    at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:149)

caused by: javax.persistence.PersistenceException: Failed to update database schema
    at com.atlassian.migration.agent.store.jpa.impl.LiquibaseSchemaUpgrader.upgrade(LiquibaseSchemaUpgrader.java:35)

caused by: liquibase.exception.LockException: Could not acquire change log lock. Currently locked by 262e58e7ef0d (172.17.0.3) since 4/28/20 11:54 AM
    at liquibase.lockservice.StandardLockService.waitForLock(StandardLockService.java:230)

 

4 answers

To avoid leaving any CCMA tables behind, use this approach (combined with the steps already provided in the answers above).

SELECT CONCAT('DROP TABLE ', table_name, ';') FROM information_schema.tables WHERE table_catalog = '<database name>' AND table_schema = 'public' AND table_name LIKE 'mig_%';

The SELECT statement above will produce a list of the current CCMA tables, so you can drop them.

That'll help you avoid leaving MIG_ tables behind.

For Oracle, you'll want to try this:

SELECT CONCAT(CONCAT('DROP TABLE ', TABLE_NAME), ';') FROM USER_TABLES WHERE TABLE_NAME LIKE 'MIG_%';

Hello everyone, 

In case you're still running into this error, besides following all the directions from this link, you should also include an additional table to remove as well. Add to your list the table named:

  • mig_check_override

This should help you overcome this hiccup. 

Cheers,
Fábio

Hello Eva,

 

Thank you for posting your question here in the community this way many other users can benefit our answers! 

Indeed using Confluence with H2 (Embedded database) is not recommended for a production environment, however, let me try to go through a procedure and how we can unblock you so hopefully you can migrate your data over to the Cloud and not have to worry about all these aspects of having to manage your own server.

1. Make sure the system user of Confluence has all the necessary privileges.

2. Let's try to go through a reset of the Confluence Cloud Migration Assistant installation.

a) Shutdown Confluence service

b) Delete all tables related to the Assistant

DELETE FROM public.plugindata WHERE plugindata.pluginkey = 'com.atlassian.migration.agent';
DROP TABLE public.mig_app_assessment_info;
DROP TABLE public.mig_detected_event_log;
DROP TABLE public.mig_check_result;
DROP TABLE public.mig_analytics_event;
DROP TABLE public.mig_attachment;
DROP TABLE public.mig_db_changelog;
DROP TABLE public.mig_db_changelog_lock;
DROP TABLE public.mig_sequences;
DROP TABLE public.mig_stats;
DROP TABLE public.mig_step;
DROP TABLE public.mig_task;
DROP TABLE public.mig_work_item;
DROP TABLE public.mig_plan;
DROP TABLE public.mig_cloud_site;

c) Clear out the Plugin cache by removing the following folders:

  • <confluence-home>/bundled-plugins
  • <confluence-home>/plugins-cache
  • <confluence-home>/plugins-osgi-cache
  • <confluence-home>/plugins-temp
  • <confluence-home>/bundled-plugins_language

d) Start Confluence service

You can go now and search for the assistant through the find app menu of your Confluence server, reinstall it, and if needed upgrade to the latest version which I believe is 3.0.2

Further details on the procedure above can be found in the following article.

- https://confluence.atlassian.com/confkb/restore-the-cloud-migration-assistant-for-confluence-to-the-default-version-974378747.html

Let's see if restarting everything from scratch will get the DB lock removed and allow you to use the Assistant.

If you continue to have problems while using the assistant, send us some logs just as you did before and we will try to help you :)

 

Cheers,

 

Daniel - Atlassian Cloud Migration

Hi, I have the same problem, with the same exact error message.

Confluence (on-prem) Server - 6.9.0

Cloud Migration Assistant for Confluence - 3.0.4

DB: MS SQL Server (10.50.6560)

I did all the steps described above with cleaning data and removing plugins cache, reinstalled plugin, and get the same error.

P.S. There were no "mig_..." tables in the database.

Actually, the error message is different:

org.apache.velocity.exception.MethodInvocationException: Invocation of method 'getInitialState' in class com.atlassian.migration.agent.web.AppAction threw exception com.atlassian.util.concurrent.LazyReference$InitializationException: javax.persistence.PersistenceException: Failed to update database schema at /templates/app.vm[line 21, column 44]
    at org.apache.velocity.runtime.parser.node.ASTIdentifier.execute(ASTIdentifier.java:223)

caused by: com.atlassian.util.concurrent.LazyReference$InitializationException: javax.persistence.PersistenceException: Failed to update database schema
    at com.atlassian.util.concurrent.LazyReference.getInterruptibly(LazyReference.java:149)

caused by: javax.persistence.PersistenceException: Failed to update database schema
    at com.atlassian.migration.agent.store.jpa.impl.LiquibaseSchemaUpgrader.upgrade(LiquibaseSchemaUpgrader.java:35)

caused by: liquibase.exception.LockException: liquibase.exception.DatabaseException: Column, parameter, or variable #2: Cannot find data type BOOLEAN. [Failed SQL: CREATE TABLE MIG_DB_CHANGELOG_LOCK (ID INT NOT NULL, LOCKED BOOLEAN NOT NULL, LOCKGRANTED datetime, LOCKEDBY VARCHAR(255), CONSTRAINT PK_MIG_DB_CHANGELOG_LOCK PRIMARY KEY (ID))]
    at liquibase.lockservice.StandardLockService.acquireLock(StandardLockService.java:289)

caused by: liquibase.exception.DatabaseException: Column, parameter, or variable #2: Cannot find data type BOOLEAN. [Failed SQL: CREATE TABLE MIG_DB_CHANGELOG_LOCK (ID INT NOT NULL, LOCKED BOOLEAN NOT NULL, LOCKGRANTED datetime, LOCKEDBY VARCHAR(255), CONSTRAINT PK_MIG_DB_CHANGELOG_LOCK PRIMARY KEY (ID))]
    at liquibase.executor.jvm.JdbcExecutor$ExecuteStatementCallback.doInStatement(JdbcExecutor.java:356)

caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Column, parameter, or variable #2: Cannot find data type BOOLEAN.
    at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:260)

Shannon S Atlassian Team Jun 26, 2020

Hi @Eva Jaritz,

Welcome to Atlassian Community! I'm happy that Repi was able to point you in the direction of this article.

Could you let the know if you were able to solve your issue with that? If you still need any help, I can get the migration team involved.

Looking forward to hearing from you soon!

Shannon 

Like Eva Jaritz likes this

Hi  @Shannon S ,

Thanx for the warm welcome!

Sorrily we weren't able to fix the problem, because we are currently working with the integrated Confluence Database and don't know, how to get there. Additionally our Confluence runs on Dokker, which doesn't make things easier... (one of the reasons why we want to migrate)

But what I find astonishing is, that the JIRA migration runs smooth (also with the intgrated Database & Dokker).

Perhaps you can answer me a question:

is there another way to migrate from Server to Cloud - except the Confluence Cloud Migration Assistant or doing it manually page per page via copy & paste)?

Thanks so much in advance for your answer!

Shannon S Atlassian Team Jun 26, 2020

Hi Eva,

The Confluence Cloud Migration Assistant is honestly the best way to migrate from Server to Cloud. We need to determine why it's not working for you, especially if other users in the future might have the same problem.

I've passed on your case to our migration team; let me find out how we can proceed, and I'll let you know!

Take care,

Shannon

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS

Atlassian Community Events