既定では、Confluence は添付ファイルをホームディレクトリ (ファイルシステムなど) に保存します。 

以前の Confluence バージョンからアップグレードした場合は、データベースまたは WebDAV に添付ファイルがまだ保存されている可能性があります。この保存方法はサポートされなくなりました。

サポートされている保管方法への移行手順については、下記をご参照ください。 

On this page:

関連ページ

添付ファイルの保存方法

ローカルのファイル システム

既定では、Confluence は添付ファイルを、構成済みの Confluence ホーム フォルダの attachments ディレクトリに保存します。

S3 オブジェクト ストレージ

Starting from Confluence 8.1, you can also store your attachment data on Amazon S3 object storage. We recommend this method if your team has large or increasing data needs and requires the ability to scale efficiently. Learn more about configuring S3 object storage.

添付ファイル データを移行する

ファイル システムから S3 オブジェクト ストレージへ

既存の添付ファイル データがあって Amazon S3 を使用する場合は、添付ファイルを Confluence が使用できるように S3 バケットに移行する必要があります。

移行するには、以下の手順を実行します。

  1. Confluence 8.1 以降を使用していることを確認します。
  2. Check that the migration to v4 hierarchical attachment storage structure is complete. Learn how to do this
  3. Create a new Amazon S3 bucket for Confluence (follow step 1 on Configuring S3 object storage).
  4. v4 添付ファイル データ (${confluenceHome}/attachments/v4) を物理ソースから S3 バケットのルート プレフィックス confluence/attachments/ に移行します。
    下記はその例です。

    ファイル システム${confluenceHome}/attachments/v4/14/0/327689/327689.1
    S3<S3_Bucket>/confluence/attachments/v4/14/0/327689/327689.1

    The physical location of this data is dependent on your environment. For example, clustered environments typically host this data in a network file system (NFS) as a shared mount. You'll need to consider you setup and the amount of attachment data that needs to be migrated. In general, we recommend using Amazon DataSync for migration. Learn how to do this

  5. 移行が完了するまで待ちます。

  6. Configure your Confluence node(s) one by one with AWS authentication details and your S3 configuration (follow steps 2 and 3 on Configuring S3 object storage).

    1. Consider putting Confluence into read-only mode to avoid data creation until all node(s) are configured for S3.
    2. 適切な構成を指定したら、各ノードを再起動する必要があります。

    3. このプロセス中に、S3 用にまだ構成されていないノードで添付ファイルが作成された場合、S3 に構成されたノードではその添付ファイル データを使用できなくなります。

  7. 次の手順で、Confluence が S3 オブジェクト ストレージを使用していることを確認します。
    1. Go to Administration menu , then General Configuration > System Information

    2. [添付ファイル保存場所のタイプ] の横に「S3」と表示されます。

    3. さらに、[Java ランタイム引数] の横には、バケット名とリージョンの両方のシステム プロパティとそれぞれの値が表示されます。

  8. 元の DataSync ジョブを再実行して最終同期を行います。これを実行する前に、すべてのノードを設定して、すべての添付ファイル データを確実に移行する必要があります。

(tick) この段階で、添付ファイル データは AWS S3 から読み書きされます。

DataSync では、ソース ファイル システムのデータが変更または削除されません。そのため、ファイル システムに保存されている添付ファイル データが不要になった場合は、そのデータを手動で削除する必要があります。

トラブルシューティング

As the source file system data is not altered or removed by DataSync, Confluence can be reverted back to reading and writing attachment data from the file system. To do this, remove the configuration below from your setenv.sh and/or confluence.cfg.xml, and restart Confluence:

  • confluence.filestore.attachments.s3.bucket.name

  • confluence.filestore.attachments.s3.bucket.region

元のファイル システムに戻す場合は、S3 に書き込まれたすべてのデータを、Confluence 管理者が手動で元のファイル システムに同期させる必要があります。