Fixing DatabaseException Errors in Confluence Cloud Migration Assistant Activation

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

要約:

The following article provides guidance on enabling the Confluence Cloud Migration Assistant (CCMA) when it encounters a DatabaseException error in the log during the activation process.

概要

When users setup the staging environment by cloning the production site, database exceptions may be observed in the logs while attempting to manage the application installed in the new environment. For instance, when the user tries to enable or reinstall the CCMA plugin, the following database exception may be recorded in the atlassian-confluence.log

Caused by: liquibase.exception.MigrationFailedException: Migration failed for changeset META-INF/db-changelog/74-add-step-metadata-column.xml::74-add-step-metadata-column.xml::MPT:
Reason: liquibase.exception.DatabaseException: ALTER command denied to user 'confluencedb_user'@'<DataCenterHostIP>' for table 'MIG_STEP' [Failed SQL: (1142) 
ALTER TABLE confluencedb.MIG_STEP ADD stepMetadata LONGTEXT NULL]

This issue arises due to the following reasons:

  1. As indicated in the documentation Database Setup For MySQL | Confluence Data Center 5.9 | Atlassian Documentation, an error will occur if the database system user is not created with the appropriate privileges.

  2. Additionally, the user must possess the necessary database manipulation privileges, including Update, Select, Insert, Alter, and others as required.

Identify the User Privileges

  1. Execute the following queries on the MySQL database to confirm whether the Confluence user exists: 

    SELECT user,host FROM mysql.user;
  2. If the user does not exist, please refer to the documentation Setup MySQL database user to create it.

  3. If the user exists, please verify the user's privileges using the below query: 

    SHOW GRANTS FOR confluencedb_user@<DataCenterHostIP>;

Steps to Fix Database Exception

  1. Run the following query to grant the user all permissions on the database. 

    GRANT ALL PRIVILEGES ON <database-name>.* TO confluencedb_user'@'<DataCenterHostIP>' IDENTIFIED BY '<password>'; 
  2. Restart the Confluence server
  3. Enable/re-install the CCMA by following the article Update or install the Confluence Cloud Migration Assistant
  4. The app will now be successfully enabled.
最終更新日 2024 年 11 月 17 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.