このページでは、Confluence を物理的に異なるサーバーに移動する方法について説明します。他の機能とは違う様々な特質がこの機能にはありますのでご注意ください。 ただし、データベースの移行、アプリケーションサーバーの移動、アップグレードについてはここでは説明しません。アトラシアンはこれらを別々の作業として 実施することを推奨しています。なお、以下の説明もご覧ください:

テストサイトおよび開発サイトの構築方法

Administrators may need to move a Confluence site from one server to another for upgrades or downtime. This page tells you how to copy a Confluence site from one server to another. For example, you may want to transfer your current production snapshot to a test server as permitted in the licence agreement.

  • 移行作業中はアップグレードを行わないでください。 データベース、アプリケーションサーバー、Confluence のバージョンの切り替えを行う場合は、他の作業と切り離してそれらの切り替え作業を実施し、切り替えに伴う問題が生じていないことを他の作業を始める前に確認してください。
  • Development licenses are available for any Commercial or Academic license. Create one or contact Atlassian for help.

On this page:

同一のオペレーティングシステムを有するサーバーへの Confluence の移行

両方のサーバーのオペレーティングシステムが同一である場合、ホームフォルダーおよびインストールフォルダーを直接コピーすることにより、元と同じ外部データベースを利用し、同一のユーザー管理情報を設定することができます。

  1. 元のサーバーにおいて Confluence のインストールディレクトリとホームディレクトリの ZIP 圧縮ファイルを作成します。
  2. On the new server, unzip the install and home directories. Windows users should avoid unzipping with the Windows built-in extractor, instead use Winzip or the free 7Zip.

    ホームディレクトリの場所を変更する場合は、Confluence install\confluence\WEB-INF\classes ディレクトリを開き、confluence-init.properties を編集して、'confluence.home=' で始まる行を修正します。

  3. EAR/WAR ディストリビューションを使用している場合、必要に応じて、war ファイルの場所を変更します。このファイルは、Tomcat を使用しているときは多くの場合 /Conf/Catalina/localhost にあります。ここで、docbase 属性が正しい場所をポイントしていることを確認してください。
  4. このステップはどのデータベースを使用しているかによって異なります:  
    • 内部データベースを使用している場合、データベースの内容はホームディレクトリに保存されています。移行完了後に、外部データベースへの切り替えを実行してください。内部データベースは評価用であり本番環境での利用は推奨できません。
    • 別サーバー上の外部データベースを使用している場合: ユーザーアカウントまたはデータソース権限を変更して、移行先サーバーに元のサーバーと同一のネットワークアクセス権限を付与します。次に、ホスト名が解決されて指定したポートにおいてデータベース接続のリスニングが開始されることを移行先サーバーから確認します。
    • ローカルにホストされた外部データベース (localhost) の場合: 元のサーバーで、データベースのダンプ バックアップ用ネイティブツールを使用してデータベースのバックアップを手動で作成します。そのデータベースバックアップを移行先サーバーにコピーします。
  5. 移行先サーバーにおいて、元のサーバーと同一バージョンになるようにデータベースのインストールまたはアップグレードを行います。
  6. データベースバックアップをインポートします。
  7. 元サーバーと同一のユーザー名とパスワードを有するデータベースユーザーアカウントを作成します。
  8. 作成したデータベースユーザーに、インポートされたデータベースに対するフルアクセス権限を付与します。
  9. データベース管理ツールを使用して、そのユーザーがローカルホストからログインできることを確認します。
  10. このステップはデータベースへの接続方法によって異なります:
    1. データベース接続に JDBC (既定の接続方法) を使用している場合、データベース接続情報を変更するときは Confluence のホームディレクトリに移動して confluence.cfg.xml を編集します。接続 URL は、hibernate.connection.url で設定します。この URL が本番環境用データベースサーバーをポイントしていないことを確認してください。
    2. If you use a data source, follow the instructions for your database type and ensure the data source points to the new database: PostgreSQLMySQLSQL Server or Oracle.
  11. If you are using internal user management, skip this step. For users who have JIRA or LDAP integration, provide the new server with network or local access to the same hosts as the original. If this is a true test site, set up a test of your JIRA site or LDAP server so as not to disrupt production systems and change the server.xml or atlassian-user.xml files (Confluence 3.4 and below), or modify the directory settings in Confluence Admin > User Directories (Confluence 3.5 and above) to point to the appropriate test servers. Note that it might be acceptable to use a production connection here, as users won't be logging on to the test system in high volume.
  12. 適宜、テストシステムからメールが送信されないことを確認します。
  13. If you have previously installed Confluence using the guided installer and plan on starting Confluence using the startup or start-confluence scripts in the Confluenceinstall/bin/ directory, check setenv.sh (Unix/Linux) or setenv.bat (Windows) in the same directory. If there is a JRE_HOME set, ensure that the path to the JRE is up to date in regards to the new environment.
  14. Confluence を起動します。
  15. Go to Administration > License Details and add your development license key. You can generate one at http://my.atlassian.com. There are more details in How to get a Confluence Developer license.
  16. Confluence を Windows のサービスとして実行する設定にしていた場合は、これらの操作を繰り返します
  17. 開発ライセンスキーを追加します。
  18. Some customers have experienced problems with Confluence's search functions after performing a migration, or that the content of their {recently-updated} macro is not being updated correctly. Errors in the atlassian-confluence.log file corroborate such problems. Hence, to avoid these issues, it is strongly recommended that you perform a rebuild of your content indices after performing a migration.

異なるオペレーティングシステムを有するサーバーへの Confluence の移行

Windows から Linux への移行

You will need to replace the backslash with forward slash in the following lines in confluence.cfg.xml:

    <property name="attachments.dir">${confluenceHome}/attachments</property>
    <property name="lucene.index.dir">${confluenceHome}/index</property>
    <property name="webwork.multipart.saveDir">${confluenceHome}/temp</property>

データベースツールを利用した移行 (推奨)

本番バックアップ計画 に基づくバックアップを行っている場合は、次の手順で作業を進めてください。

  1. Download the proper distribution (the same one you have from your original site) from the Download Archive.
  2. Confluence のホームディレクトリを元のサーバーからコピーします (OS が異なっていてもここで行う操作はコピーです。インストールしてはいけません)。
  3. ホームディレクトリの場所を変更する場合は、Confluence install\confluence\WEB-INF\classes ディレクトリを開き、confluence-init.properties を編集して、'confluence.home=' で始まる行を修正します。
  4. 元のサーバーにローカルに格納されている外部データベースの場合は、データベースのダンプ・バックアップ用ネイティブツールを使用してデータベースのバックアップを手動で作成します。
  5. そのデータベースバックアップを移行先サーバーにコピーします。
  6. 移行先サーバーにおいて、元のサーバーと同一バージョンになるようにデータベースのインストールまたはアップグレードを行います。
  7. データベースバックアップをインポートします。
  8. 元サーバーと同一のユーザー名とパスワードを有するデータベースユーザーアカウントを作成します。
  9. 作成したデータベースユーザーに、インポートされたデータベースに対するフルアクセス権限を付与します。
  10. データベース管理ツールを使用して、そのユーザーがローカルホストからログインできることを確認します。
  11. データベース接続情報を変更するときは Confluence のホームディレクトリに移動して confluence.cfg.xml を編集します。接続 URL は、hibernate.connection.url で設定します。この URL が本番環境用データベースサーバーをポイントしていないことを確認してください。
  12. ユーザー管理対象が内部ユーザーのみの場合はこのステップは不要です。JIRA または LDAP を組み込んでいる場合、それらのホストへのネットワークアクセスまたはローカルアクセス権限を元のサーバーと同様に移行先サーバーに付与します。
  13. Copy server.xml, atlassian-user.xml, osuser.xml, any patches, and any other customized files velocity or properties files. If this is a true test site, set up a test of your JIRA site or LDAP server so as not to disrupt production systems and change the server.xml or atlassian-user.xml files to point to the appropriate test servers. Note that it might be acceptable to use a production connection here, as users won't be logging on to the test system in high volume.
  14. 適宜、テストシステムからメールが送信されないことを確認します。
  15. If you have previously installed Confluence using the guided installer and plan on starting Confluence using the startup or start-confluence scripts in the Confluenceinstall/bin/ directory, check setenv.sh (Unix/Linux) or setenv.bat (Windows) in the same directory. If there is a JRE_HOME set, ensure that the path to the JRE is up to date in regards to the new environment.
  16. Confluence を起動します。
  17. Go to Administration > License Details and add your development license key. You can generate one at http://my.atlassian.com. There are more details in How to get a Confluence Developer license.
  18. Confluence を Windows のサービスとして実行する設定にしていた場合は、これらの操作を繰り返します
  19. 開発ライセンスキーを追加します。
  20. Some customers have experienced problems with Confluence's search functions after performing a migration, or that the content of their {recently-updated} macro is not being updated correctly. Errors in the atlassian-confluence.log file corroborate such problems. Hence, to avoid these issues, it is strongly recommended that you perform a rebuild of your content indices after performing a migration.

XML 形式データバックアップを利用した移行 (中小規模システム向け)

注意: Confluence に組み込まれている XML エキスポートは、大きなデータセットのバックアップや移行には適していません。そのようなデータ移行に役立つサードパーティ製ツールが数多くあります。もし適切なツールを選択するために支援が必要な場合、あるいは移行作業そのものに対して支援が必要な場合、アトラシアンエキスパートの 1 社をご紹介することができます。

本番バックアップ計画 に基づくバックアップを行っていない場合は、通常の XML 形式データバックアップを作成し、それを移行先サーバー上の Confluence にインポートすることで Confluence を別のサーバーマシンに移行できます。

  1. 以下の手順で XML 形式データバックアップを作成します:
    1. Choose the cog icon , then choose General Configuration under Confluence Administration.
    2. バックアップと復元を選択する。
    3. 添付ファイルのバックアップ オプションにチェックマークを付け、バックアップをクリックする。
  2. 利用中の Confluence のバージョンを確認します。これは Confluence の各ページ下部に表示されています。これは Confluence の各ページ下部に表示されています。
  3. Download Confluence to the new server. Get the version of Confluence that you identified above, but for the operating system of the new server. You may be using either the latest Confluence version, or an older version.
  4. 移行先サーバーに Confluence をインストールします。
  5. Go to Administration > License Details and add your development license key. You can generate a license at http://my.atlassian.com. You can find more details in How to get a Confluence Developer license.
  6. 管理 > バックアップと復元 に移動し、XML 形式データバックアップをリストアします。
  7. 適宜、テストシステムでメール連絡ができないことを確認します。
  8. Some customers have experienced problems with Confluence's search functions after performing a migration, or that the content of their {recently-updated} macro is not being updated correctly. Errors in the atlassian-confluence.log file corroborate such problems. Hence, to avoid these issues, it is strongly recommended that you rebuild your content indices after performing a migration.

本番環境システムとの通信遮断設定

外部システムとの通信を遮断するため、インバウンドおよびアウトバウンド両方向のメールサービスを無効化します。

  1. 次のデータベースクエリを実行してグローバルなアウトバウンドメールを無効化します:

    SELECT * FROM BANDANA WHERE BANDANAKEY = 'atlassian.confluence.smtp.mail.accounts';
    
  2. 次のデータベースクエリを実行してスペースレベルでのメールアーカイブ機能を無効化します:

    SELECT * FROM BANDANA WHERE BANDANAKEY = 'atlassian.confluence.space.mailaccounts';
    

指定したアカウントを削除してもよければ、上記クエリの 'SELECT * FROM' を 'DELETE FROM' に書き換えます。

以上の設定が完了すると、テストサイトを起動してもメールの送受信は行われなくなります。なお、この他にプラグイン (SQL マクロ、 JIRA マクロなど) が本番環境システムにアクセスする可能性があることに留意してください。外部システムにおいてこれらによるコンテンツの書き換えや負荷の増大が発生する場 合は、テストサイト起動後にそれらを速やかに無効化する必要があります。

HTTPS から HTTP への移行

SSL によって保護されたサーバーから SSL による保護のないサーバーに移行する必要が生ずることがあります。例えば、Confluence サイトを本番環境からテストサイトにコピーするときにこれが生じます。

HTTPS から HTTP に移行するには、「セキュアなログインとページセキュリティのための SSL の追加」ページの説明に従って行った HTTPS 固有の設定をすべて元に戻します。

注意

  • If you wish to merge two Confluence sites, you can consider using the remote import plugin. This plugin is currently not supported. The supported method would be to export a space and then import each space one by one. The two Confluence sites must be running the same version of Confluence.
  • ラベルなし