セルフホストエンジンガイド
Red Hat Enterprise Virtualization のセルフホストエンジンのインストールおよびメンテナンス
Red Hat Enterprise Virtualization Documentation Team
rhev-docs@redhat.com
概要
第1章 はじめに
表1.1 セルフホストエンジンのデプロイをサポートする OS バージョン
システムのタイプ
|
サポートされているバージョン
|
---|---|
Red Hat Enterprise Linux ホスト
|
7.2
|
Red Hat Enterprise Virtualization Hypervisor ホスト
|
7.2
|
HostedEngine-VM (Manager)
|
6.7
|
第2章 Red Hat Enterprise Virtualization Hypervisor でのセルフホストエンジンのデプロイ
2.1. Red Hat Enterprise Virtualization Hypervisor のインストール
2.2. Red Hat Enterprise Virtualization Hypervisor でのセルフホストエンジンの設定
前提条件:
- 新規インストールした Red Hat Enterprise Virtualization Hypervisor (RHEV-H) を用意する必要があります。
- セルフホストエンジン環境のストレージを準備する必要があります。ご使用のデプロイメントのストレージを用意する方法については、『管理ガイド』の「ストレージ」の章を参照してください。ストレージ共有は、少なくとも 60 GB 必要です。
- Manager および Hypervisor ホスト用の完全修飾ドメイン名を設定しておく必要があります。正引き (フォワードルックアップ) と逆引き (リバースルックアップ) の両方を DNS で設定する必要があります。
注記
評価目的で、/etc/hosts
ファイルを名前解決に使用することができます。 - Security 画面で SSH パスワード認証を有効にしておく必要があります。
- Manager 仮想マシンのオペレーティングシステムのインストールメディアを用意する必要があります。インストールには、RHEV-M Virtual Appliance を使用する方法を推奨しています。アプライアンスを使用するには、
/tmp
ディレクトリーの容量が少なくとも 60 GB で、HTTP 経由でハイパーバイザーからアプライアンスにアクセスできる状態でなければなりません。カスタマーポータルから RHEV-M Virtual Appliance をダウンロードしてください。
手順2.1 RHEV-H でのセルフホストエンジンの設定
- Deploy Hosted Engine をクリックします。
- Red Hat Enterprise Virtualization Manager 仮想マシンのインストール方法を指定します。RHEV-M Virtual Appliance を使用してインストールする場合は、アプライアンスに
http://file.domain.com/rhevm-appliance.ova
などの URL を入力します。これは、推奨される Manager のインストール方法です。Deploy をクリックしてから、Close をクリックします。または、PXE インストールが希望のインストール方法である場合は PXE Boot Engine VM を選択します。 - OK をクリックして
hosted-engine
デプロイメントスクリプトを開始します。Enter を押して操作の続行を確定します。 ストレージの設定
使用するストレージのタイプを選択します。During customization use CTRL-D to abort. Please specify the storage you would like to use (glusterfs, iscsi, fc, nfs3, nfs4)[nfs3]:
- NFS ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/nfs
- iSCSI の場合には、iSCSI ポータルの IP アドレス、ユーザー名、およびパスワードを指定して、自動検出されたリストからターゲット名を選択します。デプロイメント時に選択できる iSCSI ターゲットは 1 つのみです。
Please specify the iSCSI portal IP address: Please specify the iSCSI portal port [3260]: Please specify the iSCSI portal user: Please specify the iSCSI portal password: Please specify the target name (auto-detected values) [default]:
- Gluster ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
重要
サポートされるストレージは、レプリカ 3 の Gluster ストレージのみです。以下の設定が行われていることを確認してください。- Gluster サーバー 3 つすべての
/etc/glusterfs/glusterd.vol
ファイルで、rpc-auth-allow-insecure
をon
に設定してください。option rpc-auth-allow-insecure on
- 以下のようにボリュームを設定します。
gluster volume set volume cluster.quorum-type auto gluster volume set volume network.ping-timeout 10 gluster volume set volume auth.allow \* gluster volume set volume group virt gluster volume set volume storage.owner-uid 36 gluster volume set volume storage.owner-gid 36 gluster volume set volume server.allow-insecure on
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/gluster_volume
- Fiber Channel については、ホストのバスアダプターが設定、接続されている必要があります。設定/接続がされている場合には
hosted-engine
により、利用可能な LUN が自動で検出されます。LUN には既存のデータが含まれないようにする必要があります。The following luns have been found on the requested target: [1] 3514f0c5447600351 30GiB XtremIO XtremApp status: used, paths: 2 active [2] 3514f0c5447600352 30GiB XtremIO XtremApp status: used, paths: 2 active Please select the destination LUN (1, 2) [1]:
環境で使用するストレージドメインとストレージデータセンターの名前を選択します。[ INFO ] Installing on first host Please provide storage domain name. [hosted_storage]: Local storage datacenter name is an internal name and currently will not be shown in engine's admin UI.Please enter local datacenter name [hosted_datacenter]:
ネットワークの設定
このスクリプトは、環境の管理ブリッジとして使用可能なネットワークインターフェースコントローラー (NIC) を検出し、次にファイアウォールの設定をチェックして、コンソールから (SPICE または VNC) アクセスできるようにその設定を変更するかどうかを確認します。注記
現在、ボンディングネットワークおよび VLAN タグ付けされたネットワークのインターフェースを管理ブリッジとして設定できません。この問題を回避するには、https://access.redhat.com/solutions/1417783 から詳しい情報を確認してください。Please indicate a nic to set rhevm bridge on: (eth1, eth0) [eth1]: iptables was detected on your computer, do you wish setup to configure it? (Yes, No)[Yes]: Yes Please indicate a pingable gateway IP address [X.X.X.X]:
仮想マシンの設定
このスクリプトは、仮想マシンを作成して、Red Hat Enterprise Virtualization Manager として設定していきます。注記
Manager の仮想マシンを手動でインストールする場合は、「付録A Manager のオペレーティングシステムの手動インストール」を参照して、セルフホストエンジンの設定を完了してください。アプライアンスを使用すると、Manager 仮想マシンにユーザーの操作が必要ないため、ワークフローが簡素化されます。手動でのインストールでは、インストールを自由自在にコントロールすることができます。[ INFO ] Checking OVF archive content (could take a few minutes depending on archive size) [ INFO ] Checking OVF XML content (could take a few minutes depending on archive size) Would you like to use cloud-init to customize the appliance on the first boot (Yes, No)[Yes]? Would you like to generate on-fly a cloud-init no-cloud ISO image or do you have an existing one(Generate, Existing)[Generate]? Generate Please provide the FQDN you would like to use for the engine appliance. Note: This will be the FQDN of the engine VM you are now going to launch. It should not point to the base host or to any other existing machine. Engine VM FQDN: (leave it empty to skip): manager.example.com Automatically execute engine-setup on the engine appliance on first boot (Yes, No)[Yes]? Yes Automatically restart the engine VM as a monitored service after engine-setup (Yes, No)[Yes]? Yes Please provide the domain name you would like to use for the engine appliance. Engine VM domain: [example.com] Enter root password that will be used for the engine appliance (leave it empty to skip): p@ssw0rd Confirm appliance root password: p@ssw0rd How should the engine VM network be configured (DHCP, Static)[DHCP]? Static Please enter the IP address to be used for the engine VM: 192.168.x.x [ INFO ] The engine VM will be configured to use 192.168.x.x/24 Please provide a comma-separated list (max3) of IP addresses of domain name servers for the engine VM Engine VM DNS (leave it empty to skip): Add lines for the appliance itself and for this host to /etc/hosts on the engine VM? Note: ensuring that this host could resolve the engine VM hostname is still up to you (Yes, No)[No] Yes Please specify an alias for the Hosted Engine image [hosted_engine]: The following CPU types are supported by this host: - model_Penryn: Intel Penryn Family - model_Conroe: Intel Conroe Family Please specify the CPU type to be used by the VM [model_Penryn]: Please specify the number of virtual CPUs for the VM [Defaults to appliance OVF value: 4]: You may specify a MAC address for the VM or accept a randomly generated default [00:16:3e:77:b2:a4]: Please specify the console type you would like to use to connect to the VM (vnc, spice) [vnc]: vnc
ホストエンジンの設定
Red Hat Enterprise Virtualization 環境で識別できるようにハイパーバイザーの名前を、また管理ポータルにアクセスできるようにadmin@internal
ユーザーのパスワードを指定します。Manager 仮想マシンの FQDN を指定してください。Enter the name which will be used to identify this host inside the Administrator Portal [hosted_engine_1]: Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: p@ssw0rd Confirm 'admin@internal' user password: p@ssw0rd Please provide the name of the SMTP server through which we will send notifications [localhost]: Please provide the TCP port number of the SMTP server [25]: Please provide the email address from which notifications will be sent [root@localhost]: Please provide a comma-separated list of email addresses which will get notifications [root@localhost]:
設定のプレビュー
続行する前に、hosted-engine
スクリプトは、入力された設定値を表示して、これらの値で設定を続行するかどうかを尋ねます。Manager 仮想マシンの作成
このスクリプトでは、Manager 仮想マシンの作成、ovirt-engine
および高可用性サービスの起動、ハイパーバイザーホストと共有ストレージドメインの Manager 仮想マシンへの接続が行われます。You can now connect to the VM with the following command: /usr/bin/remote-viewer vnc://localhost:5900 Use temporary password "3042QHpX" to connect to vnc console. Please note that in order to use remote-viewer you need to be able to run graphical applications. This means that if you are using ssh you have to supply the -Y flag (enables trusted X11 forwarding). Otherwise you can run the command from a terminal in your preferred desktop environment. If you cannot run graphical applications you can connect to the graphic console from another host or connect to the serial console using the following command: socat UNIX-CONNECT:/var/run/ovirt-vmconsole-console/fabbea5a-1989-411f-8ed7-7abe0917fc66.sock,user=ovirt-vmconsole STDIO,raw,echo=0,escape=1 If you need to reboot the VM you will need to start it manually using the command: hosted-engine --vm-start You can then set a temporary password using the command: hosted-engine --add-console-password [ INFO ] Running engine-setup on the appliance ... [ INFO ] Engine-setup successfully completed [ INFO ] Engine is still unreachable [ INFO ] Engine is still unreachable, waiting... [ INFO ] Engine replied: DB Up!Welcome to Health Status! [ INFO ] Connecting to the Engine Enter the name of the cluster to which you want to add the host (Default) [Default]: [ INFO ] Waiting for the host to become operational in the engine. This may take several minutes... [ INFO ] Still waiting for VDSM host to become operational... [ INFO ] The VDSM Host is now operational [ INFO ] Shutting down the engine VM [ INFO ] Enabling and starting HA services [ INFO ] Saving hosted-engine configuration on the shared storage domain Hosted Engine successfully set up [ INFO ] Stage: Clean up [ INFO ] Generating answer file '/var/lib/ovirt-hosted-engine-setup/answers/answers-2015xx.conf' [ INFO ] Generating answer file '/etc/ovirt-hosted-engine/answers.conf' [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination [screen is terminating] Hit <Return> to return to the TUI
hosted-engine
のデプロイメントスクリプトが正常に完了すると、Red Hat Enterprise Virtualization Manager の名前とステータスが Hosted Engine 画面に表示されます。表示されるまでに数分かかる場合があります。Red Hat Enterprise Virtualization Manager は設定されハイパーバイザーホストで実行されています。Manager によりデータセンター、クラスター、ハイパーバイザーホスト、Manager 仮想マシン、Manager 仮想マシン専用の共有ストレージドメインがすでに設定されています。admin@internal ユーザーでログインして、Manager の設定やその他のリソースの追加を継続することができます。通常の仮想マシンのデータをホストして、Manager 仮想マシンを管理ポータルに表示させるために、別のデータドメインを作成する必要があります。
ovirt-engine-extension-aaa-ldap-setup
の対話型設定スクリプトを使用します。詳しい情報は、『管理ガイド』の「外部の LDAP プロバイダーの設定」を参照してください。
ovirt-hosted-engine-setup
スクリプトにより、設定時に指定した回答がファイルに保存されます。このファイルは、障害復旧 (DR) に役立ちます。--generate-answer=<file>
の引数で保存先が指定されていない場合には、応答ファイルは /etc/ovirt-hosted-engine/answers.conf
に生成されます。
注記
sshd
サービスが実行されていることを確認します。/etc/ssh/sshd_config
を編集して、以下の 2 つのオプションを yes
に変更します。
PasswordAuthentication
PermitRootLogin
sshd
サービスを再起動して、変更を有効にします。
2.3. Manager 仮想マシンの管理
hosted-engine
ユーティリティーは、Manager 仮想マシンタスクの実行を容易にするために提供されています。
第3章 Red Hat Enterprise Linux ホストでのセルフホストエンジンのデプロイ
3.1. 必要なエンタイトルメントのサブスクライブ
手順3.1 サブスクリプションマネージャーを使用した必要なチャンネルのサブスクライブ
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルの ユーザー名 と パスワード を入力します。
# subscription-manager register
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールを見つけて、プール ID を書き留めておきます。# subscription-manager list --available
- 上記のステップで特定したプール ID を使用して、
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のエンタイトルメントをシステムにアタッチします。# subscription-manager attach --pool=poolid
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- Red Hat Enterprise Linux 7 に必要なリポジトリーを有効化します。
# subscription-manager repos --enable=rhel-7-server-rpms # subscription-manager repos --enable=rhel-7-server-rhev-mgmt-agent-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
注記
カーネル関連のパッケージを更新した場合には、マシンを再起動してください。
3.2. セルフホストエンジン (Self-Hosted Engine) のパッケージのインストール
手順3.2 セルフホストエンジン (Self-Hosted Engine) のインストール
- セルフホストエンジン (Self-Hosted Engine) のパッケージをインストールします。
# yum install ovirt-hosted-engine-setup
- Manager 仮想マシンのインストールにアプライアンスを使用する場合には、オプションで RHEV-M Virtual Appliance パッケージをインストールします。
# yum install rhevm-appliance
Manager のオペレーティングシステムのインストール用に CD-ROM、ディスクまたは PXE インストールメディアのいずれかを使用することも可能です。物理 CD-ROM ドライブはサポートされません。
3.3. RHEL ベースのセルフホストエンジンの設定
hosted-engine
スクリプトは、ホストハイパーバイザーおよび Manager 仮想マシンの設定を容易にするために提供されています。このスクリプトは、一連の質問を尋ね、その回答に基づいて環境を構築していきます。
前提条件
- 新規インストールした Red Hat Enterprise Linux 7 システムに ovirt-hosted-engine-setup パッケージをインストールしておく必要があります。
- セルフホストエンジン環境のストレージを準備する必要があります。ご使用のデプロイメントのストレージを用意する方法については、『管理ガイド』の「ストレージ」の章を参照してください。
- Manager およびハイパーバイザーホスト用の完全修飾ドメイン名を設定しておく必要があります。正引き (フォワードルックアップ) と逆引き (リバースルックアップ) の両方を DNS で設定する必要があります。
- Manager のオペレーティングシステムのインストール用に CD-ROM、ディスクまたは PXE インストールメディアのいずれかを用意しておく必要があります。推奨の方法は、ディスクオプションを選択して、Manager のインストールに RHEV-M Virtual Appliance を使用することです。rhevm-appliance パッケージをインストールして、RHEV-M Virtual Appliance を取得します。CD-ROM オプションを使用するには、ISO ファイルを用意する必要があります。物理 CD-ROM ドライブはサポートしていません。
- Manager のインストールに RHEV-M Virtual Appliance を使用する場合には、
/tmp
ディレクトリーのサイズが少なくとも 60 GB 必要です。
手順3.3 RHEL ベースのセルフホストエンジンの設定
ホストエンジンデプロイメントの開始
hosted-engine
スクリプトを実行します。ネットワークや端末が切断された場合などにセッションが失われないように、screen
ウィンドウマネージャーを使用してスクリプトを実行することを推奨します。このウィンドウマネージャーがインストールされていない場合は、標準の Red Hat Enterprise Linux に含まれている screen パッケージをインストールしてください。CTRL+D のキーボードの組み合わせを使用してデプロイメントを中断し、スクリプトをいつでも終了することができます。# yum install screen
# screen hosted-engine --deploy
注記
セッションのタイムアウトまたは接続の切断の際には、screen -d -r
を実行してhosted-engine
デプロイメントセッションを復元します。ストレージの設定
使用するストレージのタイプを選択します。During customization use CTRL-D to abort. Please specify the storage you would like to use (glusterfs, iscsi, fc, nfs3, nfs4)[nfs3]:
- NFS ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/nfs
- iSCSI の場合には、iSCSI ポータルの IP アドレス、ユーザー名、およびパスワードを指定して、自動検出されたリストからターゲット名を選択します。デプロイメント時に選択できる iSCSI ターゲットは 1 つのみです。
Please specify the iSCSI portal IP address: Please specify the iSCSI portal port [3260]: Please specify the iSCSI portal user: Please specify the iSCSI portal password: Please specify the target name (auto-detected values) [default]:
- Gluster ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
重要
サポートされるストレージは、レプリカ 3 の Gluster ストレージのみです。以下の設定が行われていることを確認してください。- Gluster サーバー 3 つすべての
/etc/glusterfs/glusterd.vol
ファイルで、rpc-auth-allow-insecure
をon
に設定してください。option rpc-auth-allow-insecure on
- 以下のようにボリュームを設定します。
gluster volume set volume cluster.quorum-type auto gluster volume set volume network.ping-timeout 10 gluster volume set volume auth.allow \* gluster volume set volume group virt gluster volume set volume storage.owner-uid 36 gluster volume set volume storage.owner-gid 36 gluster volume set volume server.allow-insecure on
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/gluster_volume
- Fiber Channel については、ホストのバスアダプターが設定、接続されている必要があります。設定/接続がされている場合には
hosted-engine
により、利用可能な LUN が自動で検出されます。LUN には既存のデータが含まれないようにする必要があります。The following luns have been found on the requested target: [1] 3514f0c5447600351 30GiB XtremIO XtremApp status: used, paths: 2 active [2] 3514f0c5447600352 30GiB XtremIO XtremApp status: used, paths: 2 active Please select the destination LUN (1, 2) [1]:
環境で使用するストレージドメインとストレージデータセンターの名前を選択します。[ INFO ] Installing on first host Please provide storage domain name. [hosted_storage]: Local storage datacenter name is an internal name and currently will not be shown in engine's admin UI.Please enter local datacenter name [hosted_datacenter]:
ネットワークの設定
このスクリプトは、環境の管理ブリッジとして使用可能なネットワークインターフェースコントローラー (NIC) を検出し、次にファイアウォールの設定をチェックして、コンソールから (SPICE または VNC) アクセスできるようにその設定を変更するかどうかを確認します。注記
現在、ボンディングネットワークおよび VLAN タグの付いたネットワークのインターフェースを管理ブリッジとして設定できません。この問題を回避するには、https://access.redhat.com/solutions/1417783 から詳しい情報を確認してください。Please indicate a nic to set rhevm bridge on: (eth1, eth0) [eth1]: iptables was detected on your computer, do you wish setup to configure it? (Yes, No)[Yes]: Yes Please indicate a pingable gateway IP address [X.X.X.X]:
仮想マシンの設定
注記
Manager の仮想マシンを手動でインストールする場合は、「付録A Manager のオペレーティングシステムの手動インストール」を参照して、セルフホストエンジンの設定を完了してください。アプライアンスを使用すると、Manager 仮想マシンにユーザーの操作が必要ないため、ワークフローが簡素化されます。手動でのインストールでは、インストールを自由自在にコントロールすることができます。ブートデバイスタイプに disk を選択すると、スクリプトにより自動的に利用可能な RHEV-M Appliances が検出されます。メモリーサイズを指定してください。Please specify the device to boot the VM from (cdrom, disk, pxe) [disk]: [ INFO ] Detecting available oVirt engine appliances The following appliance have been found on your system: [1] - The oVirt Engine Appliance image (OVA) [2] - Directly select an OVA file Please select an appliance (1, 2) [1]: [ INFO ] Checking OVF archive content (could take a few minutes depending on archive size) Please specify the memory size of the appliance in MB (Defaults to OVF value: 16384):
cloud-init で Manager 仮想マシンの初期設定を行う場合にはYes
を指定します。root パスワードの設定、ネットワークやホスト名の設定、engine-setup
で使用するための応答ファイルの注入、起動時のengine-setup
の実行などのタスクを cloud-init に処理させる場合には Generate を指定します。または、cloud-init の高度な機能を活用できるように既存の cloud-init スクリプトがある場合には、Existing を選択します。次に、Manager 仮想マシンの FQDN を指定します。また、HostedEngine-VM の MAC アドレスを指定するか、任意で作成されたアドレスを受け入れます。この MAC アドレスを使用して、仮想マシンにオペレーティングシステムをインストールする前に DCHP および DNS サーバーを更新することができます。注記
cloud-init に関する詳しい情報は https://cloudinit.readthedocs.org/en/latest/ を参照してください。Would you like to use cloud-init to customize the appliance on the first boot (Yes, No)[Yes]? Yes Would you like to generate on-fly a cloud-init no-cloud ISO image or do you have an existing one(Generate, Existing)[Generate]? Generate Please provide the FQDN you would like to use for the engine appliance. Note: This will be the FQDN of the engine VM you are now going to launch. It should not point to the base host or to any other existing machine. Engine VM FQDN: (leave it empty to skip): manager.example.com Automatically execute engine-setup on the engine appliance on first boot (Yes, No)[Yes]? Yes Automatically restart the engine VM as a monitored service after engine-setup (Yes, No)[Yes]? Yes Please provide the domain name you would like to use for the engine appliance. Engine VM domain: [example.com] Enter root password that will be used for the engine appliance (leave it empty to skip): p@ssw0rd Confirm appliance root password: p@ssw0rd How should the engine VM network be configured (DHCP, Static)[DHCP]? Static Please enter the IP address to be used for the engine VM: 192.168.x.x Please provide a comma-separated list (max3) of IP addresses of domain name servers for the engine VM Engine VM DNS (leave it empty to skip): Add lines for the appliance itself and for this host to /etc/hosts on the engine VM? Note: ensuring that this host could resolve the engine VM hostname is still up to you (Yes, No)[No] Yes Please specify an alias for the Hosted Engine image [hosted_engine]: The following CPU types are supported by this host: - model_Penryn: Intel Penryn Family - model_Conroe: Intel Conroe Family Please specify the CPU type to be used by the VM [model_Penryn]: Please specify the number of virtual CPUs for the VM [Defaults to appliance OVF value: 4]: You may specify a MAC address for the VM or accept a randomly generated default [00:16:3e:77:b2:a4]: Please specify the console type you would like to use to connect to the VM (vnc, spice) [vnc]: vnc
ホストエンジンの設定
管理ポータル内で識別するためのハイパーバイザーホストの名前と、管理ポータルへアクセスするためのadmin@internal
ユーザーのパスワードを指定します。SMTP サーバーの名前と TCP ポート番号、メール通知に使用するメールアドレス、通知を受信するメールアドレス (複数ある場合はコンマ区切りリスト) を指定します。Enter the name which will be used to identify this host inside the Administrator Portal [hosted_engine_1]: Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: p@ssw0rd Confirm 'admin@internal' user password: p@ssw0rd Please provide the name of the SMTP server through which we will send notifications [localhost]: Please provide the TCP port number of the SMTP server [25]: Please provide the email address from which notifications will be sent [root@localhost]: Please provide a comma-separated list of email addresses which will get notifications [root@localhost]:
設定のプレビュー
続行する前に、hosted-engine
スクリプトは、入力された設定値を表示して、これらの値で設定を続行するかどうかを尋ねます。Manager 仮想マシンの作成
このスクリプトでは、Manager 仮想マシンの作成、ovirt-engine
および高可用性サービスの起動、ハイパーバイザーホストと共有ストレージドメインの Manager 仮想マシンへの接続が行われます。You can now connect to the VM with the following command: /usr/bin/remote-viewer vnc://localhost:5900 Use temporary password "3042QHpX" to connect to vnc console. Please note that in order to use remote-viewer you need to be able to run graphical applications. This means that if you are using ssh you have to supply the -Y flag (enables trusted X11 forwarding). Otherwise you can run the command from a terminal in your preferred desktop environment. If you cannot run graphical applications you can connect to the graphic console from another host or connect to the serial console using the following command: socat UNIX-CONNECT:/var/run/ovirt-vmconsole-console/fabbea5a-1989-411f-8ed7-7abe0917fc66.sock,user=ovirt-vmconsole STDIO,raw,echo=0,escape=1 If you need to reboot the VM you will need to start it manually using the command: hosted-engine --vm-start You can then set a temporary password using the command: hosted-engine --add-console-password [ INFO ] Running engine-setup on the appliance ... [ INFO ] Engine-setup successfully completed [ INFO ] Engine is still unreachable [ INFO ] Engine is still unreachable, waiting... [ INFO ] Engine replied: DB Up!Welcome to Health Status! [ INFO ] Connecting to the Engine Enter the name of the cluster to which you want to add the host (Default) [Default]: [ INFO ] Waiting for the host to become operational in the engine. This may take several minutes... [ INFO ] Still waiting for VDSM host to become operational... [ INFO ] The VDSM Host is now operational [ INFO ] Shutting down the engine VM [ INFO ] Enabling and starting HA services [ INFO ] Saving hosted-engine configuration on the shared storage domain Hosted Engine successfully set up [ INFO ] Stage: Clean up [ INFO ] Generating answer file '/var/lib/ovirt-hosted-engine-setup/answers/answers-2015xx.conf' [ INFO ] Generating answer file '/etc/ovirt-hosted-engine/answers.conf' [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination
hosted-engine
のデプロイメントスクリプトが正常に完了すると、Red Hat Enterprise Virtualization Manager が設定され、ハイパーバイザー上で稼働するようになります。Manager によりすでにデータセンター、クラスター、ハイパーバイザーホスト、Manager 仮想マシン、Manager 仮想マシン専用の共有ストレージドメインがすでに設定されています。admin@internal ユーザーでログインして、Manager の設定やその他のリソースの追加を継続することができます。通常の仮想マシンのデータをホストするために、別のデータドメインを作成する必要があります。
ovirt-engine-extension-aaa-ldap-setup
の対話型設定スクリプトを使用します。詳しい情報は、『管理ガイド』の「外部 LDAP プロバイダーの設定」を参照してください。
ovirt-hosted-engine-setup
スクリプトにより、設定時に指定した回答がファイルに保存されます。このファイルは、障害復旧 (DR) に役立ちます。--generate-answer=<file>
の引数で保存先が指定されていない場合には、応答ファイルは /etc/ovirt-hosted-engine/answers.conf
に生成されます。
注記
sshd
サービスが実行されていることを確認します。/etc/ssh/sshd_config
を編集して、以下の 2 つのオプションを yes
に変更します。
PasswordAuthentication
PermitRootLogin
sshd
サービスを再起動して、変更を有効にします。
3.4. Manager 仮想マシンの管理
hosted-engine
ユーティリティーは、Manager 仮想マシンタスクの実行を容易にするために提供されています。このユーティリティーは、環境内のセルフホストエンジンのホスト上であれば実行可能です。全オプションを確認するには、hosted-engine --help
を実行してください。
hosted-engine --vm-status
を実行します。Manager 仮想マシンに加えられた変更がステータスのコマンド出力に反映されるまでに 20 秒ほどかかる点に注意してください。
--== Host 1 status ==-- Status up-to-date : True Hostname : hypervisor.example.com Host ID : 1 Engine status : {"health": "good", "vm": "up", "detail": "up"} Score : 3400 stopped : False Local maintenance : False crc32 : 99e57eba Host timestamp : 248542
第4章 ベアメタルの RHEL ベースのセルフホストエンジンへの移行
4.1. セルフホスト環境の移行
hosted-engine
スクリプトを使用してこのタスクを容易化します。このスクリプトは、一連の質問を尋ね、提示された回答に基づいて環境を設定します。以下の手順では、標準の Red Hat Enterprise Virtualization 環境からの Manager は、BareMetal-Manager とします。
hosted-engine
スクリプトを実行して、セルフホストエンジンホストに使用するホストを設定して、新規 Red Hat Enterprise Virtualization の仮想マシンを作成します。engine-backup
ツールを使用して、エンジンデータベースと設定ファイルをバックアップし、そのバックアップを新規 Manager 仮想マシンにコピーして、engine-backup
の--mode=restore
パラメーターを使用してリストアします。engine-setup
を実行して、Manager 仮想マシン設定を完了します。hosted-engine
スクリプトに従って設定を完了します。
前提条件
- ovirt-hosted-engine-setup パッケージがインストールされた新規ハイパーバイザーを用意してください。サブスクリプションやパッケージのインストールに関する詳細情報は、「2章Red Hat Enterprise Virtualization Hypervisor でのセルフホストエンジンのデプロイ」を参照してください。ホストは、現在の Red Hat Enterprise Virtualization 環境でサポートされているバージョンでなければなりません。
注記
既存のホストを使用する場合には、ホストをメンテナンスモードに指定して、既存の環境からホストを削除します。詳しい情報は、『管理ガイド』の「ホストの削除」を参照してください。 - BareMetal-Manager に使用するオペレーティングシステムと同じバージョンのインストールメディアを用意してください。
- 新しい Manager の完全修飾ドメイン名と、バックアップした BareMetal-Manager のドメイン名は同じでなければなりません。また、正引き (フォワードルックアップ) と逆引き (リバースルックアップ) の両方を DNS で設定する必要があります。
- BareMetal-Manager へアクセスができ、変更を加えることができる必要があります。
手順4.1 セルフホスト環境の移行
ホストエンジンデプロイメントの開始
hosted-engine
スクリプトを実行します。ネットワークや端末が切断された場合などにセッションが失われないように、screen
ウィンドウマネージャーを使用してスクリプトを実行することを推奨します。このウィンドウマネージャーがインストールされていない場合は、標準の Red Hat Enterprise Linux に含まれている screen パッケージをインストールしてください。CTRL+D のキーボードの組み合わせを使用してデプロイメントを中断し、スクリプトをいつでも終了することができます。# yum install screen
# screen hosted-engine --deploy
注記
セッションのタイムアウトまたは接続の切断の際には、screen -d -r
を実行してhosted-engine
デプロイメントセッションを復元します。ストレージの設定
使用するストレージのタイプを選択します。During customization use CTRL-D to abort. Please specify the storage you would like to use (glusterfs, iscsi, fc, nfs3, nfs4)[nfs3]:
- NFS ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/nfs
- iSCSI の場合には、iSCSI ポータルの IP アドレス、ユーザー名、およびパスワードを指定して、自動検出されたリストからターゲット名を選択します。デプロイメント時に選択できる iSCSI ターゲットは 1 つのみです。
Please specify the iSCSI portal IP address: Please specify the iSCSI portal port [3260]: Please specify the iSCSI portal user: Please specify the iSCSI portal password: Please specify the target name (auto-detected values) [default]:
- Gluster ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
重要
サポートされるストレージは、レプリカ 3 の Gluster ストレージのみです。以下の設定が行われていることを確認してください。- Gluster サーバー 3 つすべての
/etc/glusterfs/glusterd.vol
ファイルで、rpc-auth-allow-insecure
をon
に設定してください。option rpc-auth-allow-insecure on
- 以下のようにボリュームを設定します。
gluster volume set volume cluster.quorum-type auto gluster volume set volume network.ping-timeout 10 gluster volume set volume auth.allow \* gluster volume set volume group virt gluster volume set volume storage.owner-uid 36 gluster volume set volume storage.owner-gid 36 gluster volume set volume server.allow-insecure on
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/gluster_volume
- Fiber Channel については、ホストのバスアダプターが設定、接続されている必要があります。設定/接続がされている場合には
hosted-engine
により、利用可能な LUN が自動で検出されます。LUN には既存のデータが含まれないようにする必要があります。The following luns have been found on the requested target: [1] 3514f0c5447600351 30GiB XtremIO XtremApp status: used, paths: 2 active [2] 3514f0c5447600352 30GiB XtremIO XtremApp status: used, paths: 2 active Please select the destination LUN (1, 2) [1]:
環境で使用するストレージドメインとストレージデータセンターの名前を選択します。[ INFO ] Installing on first host Please provide storage domain name. [hosted_storage]: Local storage datacenter name is an internal name and currently will not be shown in engine's admin UI.Please enter local datacenter name [hosted_datacenter]:
ネットワークの設定
このスクリプトは、環境の管理ブリッジとして使用可能なネットワークインターフェースコントローラー (NIC) を検出し、次にファイアウォールの設定をチェックして、その設定を HostedEngine-VM にコンソールで (SPICE または VNC) アクセスできるように変更するかどうかを確認します。ping 送信可能なゲートウェイの IP アドレスをovirt-ha-agent
が使用するように指定すると、HostedEngine-VM を実行するのに適したホストであるかどうかを判断しやすくなります。Please indicate a nic to set rhevm bridge on: (eth1, eth0) [eth1]: iptables was detected on your computer, do you wish setup to configure it? (Yes, No)[Yes]: Please indicate a pingable gateway IP address [X.X.X.X]:
仮想マシンの設定
このスクリプトにより、Red Hat Enterprise Virtualization Manager (ホストエンジン) として設定される仮想マシンが作成されます。以下の手順では、この仮想マシンを HostedEngine-VM と呼びます。ブートデバイス (該当する場合)、インストールメディアのパス名、CPU タイプ、仮想 CPU の数、ディスクサイズを指定します。HostedEngine-VM の MAC アドレスを指定するか、ランダムに生成された Mac アドレスを適用します。MAC アドレスは、仮想マシンにオペレーティングシステムをインストール前に DHCP サーバーを更新するのに使用することができます。HostedEngine-VM の作成に必要なメモリーサイズとコンソールの接続タイプも指定します。Please specify the device to boot the VM from (cdrom, disk, pxe) [cdrom]: The following CPU types are supported by this host: - model_Penryn: Intel Penryn Family - model_Conroe: Intel Conroe Family Please specify the CPU type to be used by the VM [model_Penryn]: Please specify the number of virtual CPUs for the VM [Defaults to minimum requirement: 2]: Please specify the disk size of the VM in GB [Defaults to minimum requirement: 25]: You may specify a MAC address for the VM or accept a randomly generated default [00:16:3e:77:b2:a4]: Please specify the memory size of the VM in MB [Defaults to minimum requirement: 4096]: Please specify the console type you want to use to connect to the VM (vnc, spice) [vnc]:
ホストエンジンの設定
Red Hat Enterprise Virtualization 環境内で識別するための Host-HE1 の名前と、管理ポータルへアクセスするためのadmin@internal
ユーザーのパスワードを指定します。HostedEngine-VM の FQDN を指定します。この手順では、FQDN に Manager.example.com を使用しています。最後に、SMTP サーバーの名前と TCP ポート番号、メール通知に使用するメールアドレス、通知を受信するメールアドレス (複数ある場合はコンマ区切りリスト) を指定します。重要
Engine で指定した FQDN は、BareMetal-Manager に指定した FQDN と同じものでなければなりません。Enter the name which will be used to identify this host inside the Administrator Portal [hosted_engine_1]: Host-HE1 Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: Confirm 'admin@internal' user password: Please provide the FQDN for the engine you want to use. This needs to match the FQDN that you will use for the engine installation within the VM: manager.example.com Please provide the name of the SMTP server through which we will send notifications [localhost]: Please provide the TCP port number of the SMTP server [25]: Please provide the email address from which notifications will be sent [root@localhost]: Please provide a comma-separated list of email addresses which will get notifications [root@localhost]:
設定のプレビュー
続行する前に、hosted-engine
スクリプトは、入力された設定値を表示して、これらの値で設定を続行するかどうかを尋ねます。Bridge interface : eth1 Engine FQDN : manager.example.com Bridge name : rhevm SSH daemon port : 22 Firewall manager : iptables Gateway address : X.X.X.X Host name for web application : Host-HE1 Host ID : 1 Image size GB : 25 Storage connection : storage.example.com:/hosted_engine/nfs Console type : vnc Memory size MB : 4096 MAC address : 00:16:3e:77:b2:a4 Boot type : pxe Number of CPUs : 2 CPU Type : model_Penryn Please confirm installation settings (Yes, No)[No]:
HostedEngine-VM の設定
次にこのスクリプトは、HostedEngine-VM として設定する仮想マシンを作成し、接続情報を表示します。hosted-engine
スクリプトが Host-HE1 上で続行される前に、HostedEngine-VM にオペレーティングシステムをインストールする必要があります。[ INFO ] Stage: Transaction setup ... [ INFO ] Creating VM You can now connect to the VM with the following command: /usr/bin/remote-viewer vnc://localhost:5900 Use temporary password "5379skAb" to connect to vnc console. Please note that in order to use remote-viewer you need to be able to run graphical applications. This means that if you are using ssh you have to supply the -Y flag (enables trusted X11 forwarding). Otherwise you can run the command from a terminal in your preferred desktop environment. If you cannot run graphical applications you can connect to the graphic console from another host or connect to the console using the following command: virsh -c qemu+tls://Test/system console HostedEngine If you need to reboot the VM you will need to start it manually using the command: hosted-engine --vm-start You can then set a temporary password using the command: hosted-engine --add-console-password The VM has been started. Install the OS and shut down or reboot it. To continue please make a selection: (1) Continue setup - VM installation is complete (2) Reboot the VM and restart installation (3) Abort setup (4) Destroy VM and abort setup (1, 2, 3, 4)[1]:
以下のコマンドで VNC プロトコルを使用して仮想マシンに接続します。FQDN は、セルフホストエンジンの完全修飾ドメイン名または IP アドレスに置き換えます。/usr/bin/remote-viewer vnc://FQDN:5900
仮想マシンのオペレーティングシステムのインストール
hosted-engine スクリプトで作成した仮想マシン HostedEngine-VM に接続して、Red Hat Enterprise Linux 6.7 のオペレーティングシステムをインストールします。ホストと仮想マシンの同期
Host-HE1 に戻り、オプション 1 を選択してhosted-engine
デプロイメントスクリプトを続行します。(1) Continue setup - VM installation is complete
Manager のインストール
HostedEngine-VM に接続して、適切な Red Hat Enterprise Virtualization Manager リポジトリーにサブスクライブします。『インストールガイド』の「必要なエンタイトルメントのサブスクライブ」を参照してください。インストール済みのパッケージには、すべて最新のバージョンが使用されていることを確認して、rhevm パッケージをインストールします。# yum update
# yum install rhevm
BareMetal-Manager の無効化
BareMetal-Manager (構築済みの Red Hat Enterprise Virtualization 環境の Manager) に接続して engine を停止し、実行されないようにします。# service ovirt-engine stop # chkconfig ovirt-engine off
注記
BearMetal-Manager の停止は必須ではありませんが、バックアップ作成後に環境へ変更が加えられないようにするために停止することを推奨します。これは、BareMetal-Manager と HostedEngine-VM が同時に既存のリソースを管理するのを防ぐことにもなります。DNS の更新
Red Hat Enterprise Virtualization 環境の FQDN が HostedEngine-VM の IP アドレスと Host-HE1 でhosted-engine
デプロイメントスクリプトを設定する際に指定した以前の FQDN と相関するように DNS を更新します。本手順では、FQDN は manager.example.com に設定されています。これは、移行先のホストエンジン設定では、engine に指定した FQDN は移行の engine に設定したものと同じでなければならないためです。BareMetal-Manager のバックアップ作成
BareMetal-Manager に接続して、--mode=backup
、--file=FILE
、--log=LogFILE
のパラメーターを指定してengine-backup
コマンドを実行し、バックアップモード、バックアップ用に使用および作成するバックアップファイル名、バックアップログを格納するために作成するログファイルの名前を指定します。# engine-backup --mode=backup --file=FILE --log=LogFILE
バックアップファイルの HostedEngine-VM へのコピー
BareMetal-Manager 上から、バックアップファイルを HostedEngine-VM にセキュアコピーします。以下の例では、[manager.example.com] が HostedEngine-VM の FQDN で、/backup/ が指定のフォルダーまたはパスです。指定のフォルダーまたはパスが存在しない場合は、HostedEngine-VM に接続して、そのフォルダーまたはパスを作成した後に BareMetal-Manager からバックアップをセキュアコピーします。# scp -p FILE LogFILE manager.example.com:/backup/
バックアップファイルでの HostedEngine-VM の復元
「セルフホストエンジン Manager の手動での復元」を参照してください。復元の手順の新しい Manager へのバックアップファイルのコピー
のステップは前の手順で実行しているので省略してください。engine-setup
の実行後にこの手順に戻ります。ホストと Manager の同期
Host-HE1 に戻り、オプション 1 を選択してhosted-engine
デプロイメントスクリプトを続行します。(1) Continue setup - engine installation is complete
[ INFO ] Engine replied: DB Up!Welcome to Health Status! [ INFO ] Waiting for the host to become operational in the engine. This may take several minutes... [ INFO ] Still waiting for VDSM host to become operational... [ INFO ] The VDSM Host is now operational Please shutdown the VM allowing the system to launch it as a monitored service. The system will wait until the VM is down.
HostedEngine-VM の終了
HostedEngine-VM をシャットダウンします。# shutdown -h now
設定の確認
Host-HE1 に戻り、HostedEngine-VM のリブートが検出されていることを確認します。[ INFO ] Enabling and starting HA services Hosted Engine successfully set up [ INFO ] Stage: Clean up [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination
第5章 リソースのメンテナンスおよびアップグレード
5.1. セルフホストエンジンのメンテナンス
global
: クラスター内の全高可用性エージェントで、engine の仮想マシンの状態のモニタリングが無効化されます。global メンテナンスモードは、engine の停止を必要とする設定やアップグレードの操作に適用する必要があります。これには、たとえば Red Hat Enterprise Virtualization を新しいバージョンにアップグレードする操作や、レポートポータル に必要な rhevm-dwh と rhevm-reports のパッケージをインストールする操作が含まれます。local
: コマンドを実行するホスト上の高可用性エージェントで、engine の仮想マシンのモニタリングが無効化されます。ホストは、local のメンテナンスモードの場合には、engine の仮想マシンのホスティングから除外されます。このモードに変更された際に engine の仮想マシンがホストされている場合には、engine は適切な競合ホストがあれば別のホストに移行されます。システムへの変更やホストへの更新を適用する場合に local メンテナンスモードを使用することを推奨します。none
: メンテナンスモードを無効にし、高可用性エージェントが稼働を続けるようにします。
管理ポータルからホストをメンテナンスモードに切り替えると、ローカルメンテナンスモードが自動的にトリガーされます。グローバルメンテナンスモードを有効にするには、engine 仮想マシンを右クリックして グローバル HA メンテナンスを有効にする を選択します。
注記
hosted-engine --set-maintenance
コマンドを実行する必要があります。
テキストユーザーインターフェースで、Hosted Engine 画面から < Set Hosted Engine maintenance > を選び、メンテナンスモードを選択します。
5.2. RHEL ベースのセルフホストエンジンのアップグレード
注記
- Manager 仮想マシンを管理する高可用性エージェントをグローバルメンテナンスモードに設定します。
- Manager 仮想マシンを更新します。
- セルフホストエンジンホストをメンテナンスモードに設定します。必要な場合には、Manager 仮想マシンと他の仮想マシンがクラスター内の別のホストに移行されます。
- セルフホストエンジンホストを最新の Red Hat Enterprise Linux 7 に更新します。すべてのホストも同じ手順で更新してください。環境内にあるすべてのホストを更新することを推奨します。
- クラスター内のすべてのホストと Manager 仮想マシンが更新されたら、クラスターの互換性バージョンを 3.6 に変更します。
手順5.1 セルフホストエンジンのアップグレード
- セルフホストエンジンの全ホスト上にある高可用性エージェントを無効化します。管理ポータルで、仮想マシン タブをクリックします。engine 仮想マシンを右クリックして、グローバル HA メンテナンスを有効にする を選択し、すべてのホストをグローバルメンテナンスモードに設定します。
- Manager の仮想マシンにログインして、Red Hat Enterprise Virtualization Manager をアップグレードします。
- Red Hat Enterprise Virtualization Manager がインストールされているシステムが、Red Hat Enterprise Virtualization Manager 3.6 パッケージを取得するために必要なエンタイトルメントにサブスクライブされていることを確認してください。
# subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms
- rhevm-setup パッケージを更新します。
# yum update rhevm-setup
engine-setup
コマンドを実行してプロンプトに従い、Red Hat Enterprise Virtualization Manager をアップグレードします。# engine-setup
- Red Hat Enterprise Virtualization Manager 3.5 チャンネルを削除または無効にして、このシステムで Red Hat Enterprise Virtualization Manager 3.5 のパッケージが使用されないようにします。
# subscription-manager repos --disable=rhel-6-server-rhevm-3.5-rpms
- ベースオペレーティングシステムを更新します。
# yum update
- 管理ポータルにアクセスします。セルフホストエンジンホストを選択して、メンテナンス をクリックしてメンテナンスモードに設定します。ホストが Manager 仮想マシンをホストしている場合には、この仮想マシンは別のホストに移行されます。それ以外の仮想マシンは、仮想マシンの移行ポリシーに従って移行されます。高可用性エージェントは、自動的にローカルメンテナンスに設定されます。
- 必要なリポジトリーが有効になっていることを確認します。
# subscription-manager repos --enable=rhel-7-server-rhev-mgmt-agent-rpms
- セルフホストエンジンホストを更新します。
# yum update
- VDSM を再起動します。
# systemctl restart vdsmd
ovirt-ha-broker
とovirt-ha-agent
を再起動します。# systemctl restart ovirt-ha-broker
# systemctl restart ovirt-ha-agent
- 管理ポータルへアクセスします。同じホストを選択して、アクティブ化 をクリックします。
- すべてのセルフホストエンジンホストに対してステップ 3 から 7 の手順を繰り返し、ホストをアップグレードします。環境内に標準のホストがある場合は、バージョンを 7 にアップグレードするようにしてください。標準ホストをアップグレードするには、『アップグレードガイド』の「Red Hat Enterprise Linux 6 クラスターの Red Hat Enterprise Linux 7 へのアップグレード」のステップ 3 を参照してください。
- 管理ポータルにアクセスします。
重要
ホストの一部が non-operational にならないように、すべてのホストが Red Hat Enterprise Virtualization 3.6 に更新されている場合のみ、互換性バージョンを更新してください。- Default クラスターを選択して 編集 をクリックして クラスターの編集 ウィンドウを開きます。
- 互換バージョン のドロップダウンメニューを使用して 3.6 を選択します。OK をクリックして変更を保存し、ウィンドウを閉じます。
5.3. RHEL ベースのセルフホストエンジンを Red Hat Enterprise Linux 6 ホストから 7 ホストにアップグレードする手順
- Red Hat Enterprise Virtualization 3.5 環境で、バージョン 6 のホストをすべてバージョン 7 にアップグレードします。全セルフホストエンジンのホスト上で
hosted-engine --deploy
をもう一度実行します。同じクラスター内でバージョン 6 と 7 のホストを混在させる構成はサポートされていないため、バージョン 7 をホストするために別のクラスターを作成してください。 - Manager 仮想マシンとセルフホストエンジンホストを Red Hat Enterprise Virtualization 3.6 にアップグレードします。
- クラスター内のすべてのホストと Manager 仮想マシンが更新されたら、クラスターの互換性バージョンを 3.6 に変更します。
注記
前提条件
- Red Hat Enterprise Virtualization 3.5 環境に、バージョン 6 のセルフホストエンジンホストを 2 台以上用意する必要があります。
- Red Hat Enterprise Linux 7 インストールメディアを用意する必要があります。
手順5.2 Red Hat Enterprise Virtualization 3.5 環境での Red Hat Enterprise Linux 6 ホストから 7 ホストへのアップグレード
- バージョン 6 のクラスターと同じ設定および構成の新しいクラスターを作成します。新しいクラスターは、バージョン 7 のホストをグループ化するために使用します。仮想マシンをバージョン 6 のクラスターから新しいクラスターに、ダウンタイムなしでライブマイグレーションするには、新しいクラスターがライブマイグレーションの要件を満たしていることを確認してください。ライブマイグレーションの要件については、『仮想マシン管理ガイド』の「ライブマイグレーションの前提条件」を参照してください。新規クラスターの作成については、『管理ガイド』の「新規クラスターの作成」を参照してください。
- セルフホストエンジンホストをメンテナンスモードに設定します。ホストで実行中の仮想マシンは、環境内の他のホストに移行されます。
- セルフホストエンジンホストの 1 つにログインします。
- 管理ポータルにログインします。
- ホスト タブをクリックします。
- 結果一覧からホストを選択して、メンテナンス を押して、Ok クリックします。このアクションにより、仮想マシンがホストされないようにホストがメンテナンスモードに設定され、Manager 仮想マシンがホストされないように高可用性エージェントがローカルメンテナンスモードに指定されます。
- 20 秒後に、高可用性エージェントがローカルメンテナンスモードに設定されたことを確認します。
# hosted-engine --vm-status
- セルフホストエンジンの全ホスト上にある高可用性エージェントを無効化します。管理ポータルで、仮想マシン タブをクリックします。Manager 仮想マシンを右クリックして、グローバル HA メンテナンスを有効にする を選択し、すべてのホストをグローバルメンテナンスモードに設定します。
- ホスト タブをクリックします。結果一覧からホストを選択して、削除 を押してから OK をクリックします。
- ホストで Red Hat Enterprise Linux 7 オペレーティングシステムを再インストールする場合は Red Hat Enterprise Linux 7 インストールガイド を参照してください。Red Hat Enterprise Linux 6 ホストを Red Hat Enterprise Linux 7 にアップグレードするには https://access.redhat.com/solutions/637583 を参照してください。
- Red Hat Enterprise Linux 7 リポジトリーを有効にします。
# subscription-manager repos --enable=rhel-7-server-rpms # subscription-manager repos --enable=rhel-7-server-supplementary-rpms # subscription-manager repos --enable=rhel-7-server-rhev-mgmt-agent-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
注記
カーネル関連のパッケージを更新した場合には、マシンを再起動してください。 - セルフホストエンジン (Self-Hosted Engine) のパッケージをインストールします。
# yum install ovirt-hosted-engine-setup
hosted-engine
スクリプトを実行します。ネットワークや端末が切断された場合などにセッションが失われないように、screen
ウィンドウマネージャーを使用してスクリプトを実行することを推奨します。このウィンドウマネージャーがインストールされていない場合は、標準の Red Hat Enterprise Linux に含まれている screen パッケージをインストールしてください。CTRL+D のキーボードの組み合わせを使用してデプロイメントを中断し、スクリプトをいつでも終了することができます。# yum install screen
# screen hosted-engine --deploy
注記
セッションのタイムアウトまたは接続の切断の際には、screen -d -r
を実行してhosted-engine
デプロイメントセッションを復元します。- アップグレードするホストの設定の際に使用したストレージタイプを選択して、ストレージドメインの完全パスを指定します。次に、ホスト ID を指定するようにプロンプトが表示されます。ホスト ID には整数を指定してください。
1
以外であればどの ID を再利用することもできます。The specified storage location already contains a data domain. Is this an additional host setup (Yes, No)[Yes]? [ INFO ] Installing on additional host Please specify the Host ID [Must be integer, default: 2]:
hosted-engine
スクリプトは、最初の hosted-engine 設定で作成された応答ファイルを使用します。これには、hosted-engine スクリプトにより応答ファイルにアクセスして追加ホストにセキュアコピーできるように、FQDN または IP アドレスと、ホストのroot
ユーザーパスワードが必要となります。スクリプトにより、first host
の詳細を指定するようにプロンプトが表示されますが、解凍ファイルが全セルフホストエンジンホスト上に保存されているため、既存のセルフホストエンジンホストの詳細を指定しても構いません。[WARNING] A configuration file must be supplied to deploy Hosted Engine on an additional host. The answer file may be fetched from the first host using scp. If you do not want to download it automatically you can abort the setup answering no to the following question. Do you want to scp the answer file from the first host? (Yes, No)[Yes]: Please provide the FQDN or IP of the first host: Enter 'root' user password for host Host-HE1.example.com: [ INFO ] Answer file successfully downloaded
- Red Hat Enterprise Virtualization 環境で識別できるように、追加ホストの名前と
admin@internal
ユーザーのパスワードを指定します。Enter the name which will be used to identify this host inside the Administrator Portal [hosted_engine_2]: Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: Confirm 'admin@internal' user password:
- Enter を押して設定を続行してください。最終的に、以下のエラーメッセージで失敗します。これは、同じクラスター内に Red Hat Enterprise Linux 6 と 7 のホストを混在させる構成は現在サポートされていないためです。クラスター内の最後のホストがアップグレードされると、このエラーが表示されなくなります。
The host hosted_engine_1 is in non-operational state. Please try to activate it via the engine webadmin UI.
- 管理ポータルで ホスト タブをクリックして
hosted_engine_1
を選択します。次に、メンテナンス を選び OK をクリックします。編集 を押して、この手順の最初で作成したバージョン 7 のクラスターにホストクラスターを変更して OK をクリックしてください。 - hosted-engine のデプロイメントスクリプトのターミナルに戻り、Enter を押して
Retry
オプションを確定します。Retry checking host status or ignore this and continue (Retry, Ignore)[Retry]?
- 設定が完了したら、必要に応じて仮想マシンをホストにライブマイグレーションすることができます。
- 管理ポータルで 仮想マシン タブをクリックして、実行中の仮想マシンを選択します。
- 移行 をクリックすると、仮想マシンの移行 ウィンドウが開きます。
- 詳細パラメーター ボタンをクリックして、ホストの詳細設定を展開し、移行先のクラスターを選択します。
- ラジオボタンで ホストを自動選択 を選択するか、移行先のホストを選択 を選択して、ドロップダウンリストでホストを指定します。
- OK をクリックして、移行を開始してウィンドウを閉じます。ライブマイグレーションする仮想マシンすべてに対して、このプロセスを繰り返します。
- すべてのセルフホストエンジンホストに対して、ステップ 2 以降のステップを繰り返します。最後のセルフホストエンジンホストをアップグレードし、設定が完了したら、ホストをバージョン 7 のクラスターに以降するか、他のホストすべてを
Default
クラスターに戻すことができます。
手順5.3 Manager 仮想マシンとセルフホストエンジンホストの Red Hat Enterprise Virtualization 3.6 へのアップグレード
- セルフホストエンジンの全ホスト上にある高可用性エージェントを無効化します。管理ポータルで、仮想マシン タブをクリックします。engine 仮想マシンを右クリックして、グローバル HA メンテナンスを有効にする を選択し、すべてのホストをグローバルメンテナンスモードに設定します。
- Manager の仮想マシンにログインして、Red Hat Enterprise Virtualization Manager をアップグレードします。
- Red Hat Enterprise Virtualization Manager がインストールされているシステムが、Red Hat Enterprise Virtualization Manager 3.6 パッケージを取得するために必要なエンタイトルメントにサブスクライブされていることを確認してください。
# subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms
- rhevm-setup パッケージを更新します。
# yum update rhevm-setup
engine-setup
コマンドを実行してプロンプトに従い、Red Hat Enterprise Virtualization Manager をアップグレードします。# engine-setup
- Red Hat Enterprise Virtualization Manager 3.5 チャンネルを削除または無効にして、このシステムで Red Hat Enterprise Virtualization Manager 3.5 のパッケージが使用されないようにします。
# subscription-manager repos --disable=rhel-6-server-rhevm-3.5-rpms
- ベースオペレーティングシステムを更新します。
# yum update
- 管理ポータルでセルフホストエンジンホストを選択して、メンテナンス をクリックしてメンテナンスモードに設定します。ホストが Manager 仮想マシンをホストしている場合には、この仮想マシンは別のホストに移行されます。それ以外の仮想マシンは、仮想マシンの移行ポリシーに従って移行されます。高可用性エージェントは、自動的にローカルメンテナンスに設定されます。
- 必要なリポジトリーが有効になっていることを確認します。
# subscription-manager repos --enable=rhel-7-server-rhev-mgmt-agent-rpms
- セルフホストエンジンホストを更新します。
# yum update
- VDSM を再起動します。
# systemctl restart vdsmd
ovirt-ha-broker
とovirt-ha-agent
を再起動します。# systemctl restart ovirt-ha-broker
# systemctl restart ovirt-ha-agent
注記
しばらくすると、以下のログメッセージが/var/log/ovirt-hosted-engine-ha/agent.log
に表示されます。MainThread::INFO::2016-xx-xx 13:30:01,561::upgrade::957::ovirt_hosted_engine_ha.lib.upgrade.StorageServer::(upgrade) Upgrading to current version
MainThread::INFO::2016-02-17 13:31:58,097::upgrade::987::ovirt_hosted_engine_ha.lib.upgrade.StorageServer::(upgrade) Successfully upgraded
- 管理ポータルで同じホストを選択して、アクティブ化 をクリックします。
注記
しばらくすると、セルフホストエンジンホストでhosted-engine –vm-status
を実行した場合には、画面の出力として、ステータスが non-maintenance のアップグレード済みのホストがスコア 3400 として表示されます。 - ステップ 3 から 8 を繰り返し、すべてのセルフホストエンジンホストをアップグレードします。環境で標準のホストがある場合には、これらのホストもバージョン 7 にアップグレードされており、必要な 3.6 のリポジトリーが有効化されていることを確認してください。標準ホストをアップグレードするには、『アップグレードガイド』の「Red Hat Enterprise Linux 6 クラスタから Red Hat Enterprise Linux 7 へのアップグレード」のステップ 3 を参照してください。
hosted-engine –vm-status
を実行して、Manager 仮想マシンのステータスを確認します。ヘルスステータスがgood
の場合は、仮想マシンのステータスはup
で、スコアが 3400 となります。その場合は次の手順に進んでください。--== Host 1 status ==-- Status up-to-date : True Hostname : hypervisor.example.com Host ID : 1 Engine status : {"health": "good", "vm": "up", "detail": "up"} Score : 3400 stopped : False Local maintenance : False crc32 : 99e57eba Host timestamp : 248542
手順5.4 クラスターの互換バージョンの更新
- 管理ポータルにアクセスします。Default クラスターを選択して 編集 をクリックし、クラスターの編集 ウィンドウを開きます。
重要
ホストの一部が non-operational にならないように、すべてのホストが Red Hat Enterprise Virtualization 3.6 に更新されている場合のみ、互換性バージョンを更新してください。 - 互換バージョン のドロップダウンメニューを使用して 3.6 を選択します。OK をクリックして変更を保存し、ウィンドウを閉じます。
/var/log/ovirt-engine/engine.log
に表示されます。
2016-xx-xx 23:10:30,728 INFO [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (org.ovirt.thread.pool-6-thread-43) [36bc3d70] Correlation ID: xxxx, Call Stack: null, Custom Event ID: -1, Message: Hosted Engine storage domain imported successfully
2016-xx-xx 23:10:34,857 INFO [org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector] (org.ovirt.thread.pool-6-thread-47) [] Correlation ID: null, Call Stack: null, Custom Event ID: -1, Message: Hosted Engine VM was imported successfully
OVF_STORE
が作成され、以下のログメッセージが /var/log/ovirt-engine/engine.log
に表示されます。
2016-xx-xx 00:22:41,598 INFO [org.ovirt.engine.core.vdsbroker.irsbroker.CreateImageVDSCommand] (DefaultQuartzScheduler_Worker-19) [355787ea] START, CreateImageVDSCommand( CreateImageVDSCommandParameters:{runAsync='true', storagePoolId='00000002-0002-0002-0002-000000000068', ignoreFailoverLimit='false', storageDomainId='91d59062-f823-40b4-a27c-f58142b6423a', imageGroupId='4a7effab-e9d0-48e1-8111-cb3a173f15f7', imageSizeInBytes='134217728', volumeFormat='RAW', newImageId='bf2719c2-63f2-48a2-8245-475ef48255f4', newImageDescription='{"DiskAlias":"OVF_STORE","DiskDescription":"OVF_STORE"}', imageInitialSizeInBytes='0'}), log id: 13368b09
2016-xx-xx 00:23:13,006 INFO [org.ovirt.engine.core.vdsbroker.irsbroker.SetVolumeDescriptionVDSCommand] (org.ovirt.thread.pool-6-thread-15) [1fe540ae] ++ description={"Updated":true,"Disk Description":"OVF_STORE","Storage Domains":[{"uuid":"91d59062-f823-40b4-a27c-f58142b6423a"}],"Last Updated":"xxx IST 2016","Size":20480}
OVF_STORE
の作成前には、セルフホストエンジンホスト上の /var/log/ovirt-hosted-engine-ha/agent.log
にエラーが表示されます。
MainThread::ERROR::2016-02-18 00:23:06,076::config::234::ovirt_hosted_engine_ha.agent.hosted_engine.HostedEngine.config::(refresh_local_conf_file) Unable to get vm.conf from OVF_STORE, falling back to initial vm.conf
OVF_STORE
が作成されると、以下のログメッセージが /var/log/ovirt-hosted-engine-ha/agent.log
に表示されます。
MainThread::INFO::2016-02-18 00:23:16,588::ovf_store::110::ovirt_hosted_engine_ha.lib.ovf.ovf_store.OVFStore::(getEngineVMOVF) Extracting Engine VM OVF from the OVF_STORE
5.4. RHEV-H ベースのセルフホストエンジン環境
5.5. RHEL ベースのセルフホスト環境における追加ホストのアップグレード
手順5.5 追加ホストのアップグレード
- 管理ポータルにアクセスします。ホストを選択して、メンテナンス をクリックしてメンテナンスモードに設定します。ホストが Manager 仮想マシンをホストしている場合には、この仮想マシンは別のホストに移行されます。それ以外の仮想マシンは、仮想マシンの移行ポリシーに従って移行されます。高可用性エージェントは、自動的にローカルメンテナンスに設定されます。
- 必要なリポジトリーが有効になっていることを確認します。
# subscription-manager repos --enable=rhel-7-server-rhev-mgmt-agent-rpms
- セルフホストエンジンホストを更新します。
# yum update
- VDSM を再起動します。
# service vdsmd restart
ovirt-ha-broker
とovirt-ha-agent
を再起動します。# service ovirt-ha-broker restart
# service ovirt-ha-agent restart
- 管理ポータルへアクセスします。ホストを選択して、アクティブ化 をクリックしてホストをアクティブ化します。
- アップグレードするセルフホストエンジンホストすべてに対して同じ手順を繰り返します。
5.6. セルフホストエンジン環境からのホストの削除
手順5.6 セルフホストエンジン環境からのホストの削除
- 管理ポータルで ホスト タブをクリックします。次にホストを選択し、メンテナンス をクリックして、このホストをローカルメンテナンスモードに設定します。このアクションにより、
ovirt-ha-agent
およびovirt-ha-broker
サービスが停止します。 - ホストにログインして、リブート時にサービスが起動しないように HA サービスを無効にします。
# systemctl disable ovirt-ha-agent # systemctl disable ovirt-ha-broker
- セルフホストエンジンの設定ファイルを削除します。
- RHEL ベースのハイパーバイザーの場合:
# rm /etc/ovirt-hosted-engine/hosted-engine.conf
- RHEV-H の場合:
# rm /etc/ovirt-hosted-engine/hosted-engine.conf # unpersist /etc/ovirt-hosted-engine/hosted-engine.conf
- 管理ポータルで同じホストを選択して 削除 をクリックすると、ホストの削除 の確認ウィンドウが開きます。OK をクリックしてください。
第6章 RHEL ベースのセルフホスト環境のバックアップと復元
6.1. バックアップと復元の概要
engine-backup
ツールを使用したバックアップの手法がサポートされており、この手法では、Manager 仮想マシンが含まれるホストやこの環境内でホストされる他の仮想マシンはバックアップされず、Red Hat Enterprise Virtualization Manager 仮想マシンのみをバックアップできます。本章で説明するシナリオでは、仮想マシンの移行を行うために少なくとも 2 台のセルフホストエンジンホストがバックアップ環境に必要です。
- セルフホストエンジンホストに仮想負荷がかからないように、ホストをメンテナンスモードに指定します。このホスト上にある仮想マシンは、同じ環境内の他のセルフホストエンジンホストに移行されます。このホストは、フェイルオーバーホストとしても知られています。
- フェイルオーバーホストで
engine-backup
コマンドを実行して、Red Hat Enterprise Virtualization Manager 構成設定およびデータベースのコンテンツをバックアップします。
- 復元先のホストを選択します。新規インストールした Red Hat Enterprise Linux ホストまたはフェイルオーバーホストを使用することができます。新規インストールしたホストを使用する場合には、必要なエンタイトルメントにサブスクライブして、
ovirt-hosted-engine-setup
をインストールします。「必要なエンタイトルメントのサブスクライブ」を参照してください。フェイルオーバーを使用する場合には、セルフホストエンジン設定を削除して、再利用できるようにします。「セルフホストエンジン環境からのホストの削除」 を参照してください。 - Red Hat Enterprise Virtualization Manager の構成設定およびデータベースの内容を新しい Manager 仮想マシンに復元します。
- ステータスが Non Operational のホストエンジンのホストを削除して、復元後のセルフホストエンジン環境で再インストールします。
前提条件
- 復元先の物理ホストを用意する必要があります。新規ホスト、フェイルオーバーホストのいずれかを使用することができます。
- 新規ホストおよび Manager のオペレーティングシステムのバージョンは、バックアップしたホストと Manager のバージョンと同じでなければなりません。
- 新しい環境には Red Hat サブスクリプションマネージャーのエンタイトルメントが必要です。サブスクリプションが必要なリポジトリー一覧は、「必要なエンタイトルメントのサブスクライブ」 を参照してください。
- 新しい Manager の完全修飾ドメイン名と、バックアップした Manager のドメイン名は同じでなければなりません。また、正引き (フォワードルックアップ) と逆引き (リバースルックアップ) の両方を DNS で設定する必要があります。
6.2. セルフホストエンジンの Manager 仮想マシンのバックアップ
engine-backup
ツールを使用し、ovirt-engine
サービスを中断せずにバックアップを実行することができます。engine-backup
ツールがバックアップできるのは、Red Hat Enterprise Virtualization Manager の仮想マシンのみで、Manager 仮想マシンを含むホストまたはこの環境内でホストされる他の仮想マシンはバックアップされません。
手順6.1 既存の Red Hat Enterprise Virtualization Manager のバックアップ
フェイルオーバー先のホストの準備
フェイルオーバーホスト (環境内にあるホストエンジンのホストの 1 つ) は、メンテナンスモードに設定して、バックアップ時に仮想負荷がない状態にします。このホストは後ほど、復元したセルフホストエンジン環境をデプロイする際に使用することができます。今回のシナリオでは、ホストエンジンのホストはどれでもフェイルオーバーホストとして使用することができますが、Host 1
を使用すると、復元のプロセスがより簡単になります。Host 1
ホストのデフォルト名はhosted_engine_1
で、これは、ホストエンジンのデプロイメントスクリプトが最初に実行された際に設定されたものです。- ホストエンジンのホストの 1 つにログインします。
hosted_engine_1
ホストがHost 1
であることを確認します。# hosted-engine --vm-status
- 管理ポータルにログインします。
- ホスト タブをクリックします。
- 結果一覧から
hosted_engine_1
ホストを選択して、メンテナンス をクリックします。 - OK をクリックします。
ホストの仮想負荷によっては、全仮想マシンが移行されるまでしばらく時間がかかる場合があります。ホストのステータスがMaintenance
に変わってから次のステップに進んでください。Manager のバックアップ作成
Manager の仮想マシン上で、仮想マシンの構成設定とデータベースの内容をバックアップします。[EngineBackupFile] はバックアップファイルのファイル名に、[LogFILE] はバックアップログのファイル名に置き換えます。# engine-backup --mode=backup --file=[EngineBackupFile] --log=[LogFILE]
外部サーバーへのファイルのバックアップ
外部サーバーにファイルをバックアップします。以下の例では、[Storage.example.com] は、必要になるまでバックアップを格納するネットワークストレージサーバーの完全修飾ドメイン名に、/backup/ は指定したフォルダーまたはパスに置き換えます。仮想マシンの構成設定とデータベースの内容を復元するには、このバックアップファイルにアクセス可能である必要があります。# scp -p [EngineBackupFiles] [Storage.example.com:/backup/EngineBackupFiles]
フェイルオーバーホストの有効化
hosted_engine_1
ホストのメンテナンスモードから切り替えます。- 管理ポータルにログインします。
- ホスト タブをクリックします。
- 結果一覧から
hosted_engine_1
を選択します。 - アクティブ化 をクリックします。
6.3. 復元環境として使用する新規セルフホストエンジン環境の構築
Host 1
は hosted_engine_1
というデフォルトのホスト名を使用します。以下の手順でもこの名称を使用します。セルフホストエンジンの復元プロセスの性質上、フェイルオーバーホストを削除してから、復元したエンジンの最終同期を実行する必要があります。ただし、これは、バックアップ時に、ホスト上に仮想負荷がない場合にしか実行できません。また、バックアップ環境に使用していない別のハードウェアにバックアップを復元することも可能です。その場合には、この問題を考慮する必要はありません。
重要
手順6.2 復元環境として使用するために新規セルフホスト環境を構築する方法
DNS の更新
Red Hat Enterprise Virtualization 環境の完全修飾ドメイン名と新規 Manager の IP アドレスが相関するように、DNS を更新してください。以下の手順では、完全修飾ドメイン名は Manager.example.com に設定されています。engine に指定する完全修飾ドメイン名は、バックアップ元の engine を設定する際に指定したものと同一の名前を使用する必要があります。ホストエンジンデプロイメントの開始
新規インストールされた Red Hat Enterprise Linux ホストでhosted-engine
デプロイメントスクリプトを実行します。CTRL+D のキーの組み合わせを使用してデプロイメントを中断すると、スクリプトを随時終了することができます。ネットワーク経由でhosted-engine
デプロイメントスクリプトを実行する場合には、ネットワークまたはターミナルの中断が発生した場合にセッションが失われないようにscreen
ウィンドウマネージャーを使用することを推奨します。screen がインストールされれいない場合には、先にインストールしてください。# screen
# hosted-engine --deploy
初期化の準備
このスクリプトは最初に、セルフホストエンジン環境で対象のホストをハイパーバイザーとして使用することについての確認を要求します。Continuing will configure this host for serving as hypervisor and create a VM where you have to install oVirt Engine afterwards. Are you sure you want to continue? (Yes, No)[Yes]:
ストレージの設定
使用するストレージのタイプを選択します。During customization use CTRL-D to abort. Please specify the storage you would like to use (glusterfs, iscsi, fc, nfs3, nfs4)[nfs3]:
- NFS ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/nfs
- iSCSI の場合には、iSCSI ポータルの IP アドレス、ユーザー名、およびパスワードを指定して、自動検出されたリストからターゲット名を選択します。デプロイメント時に選択できる iSCSI ターゲットは 1 つのみです。
Please specify the iSCSI portal IP address: Please specify the iSCSI portal port [3260]: Please specify the iSCSI portal user: Please specify the iSCSI portal password: Please specify the target name (auto-detected values) [default]:
- Gluster ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
重要
サポートされるストレージは、レプリカ 3 の Gluster ストレージのみです。以下の設定を完了しておいてください。- Gluster サーバー 3 つすべての
/etc/glusterfs/glusterd.vol
ファイルで、rpc-auth-allow-insecure
をon
に設定してください。option rpc-auth-allow-insecure on
- 以下のようにボリュームを設定します。
gluster volume set volume cluster.quorum-type auto gluster volume set volume network.ping-timeout 10 gluster volume set volume auth.allow \* gluster volume set volume group virt gluster volume set volume storage.owner-uid 36 gluster volume set volume storage.owner-gid 36 gluster volume set volume server.allow-insecure on
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/gluster_volume
- Fiber Channel については、ホストのバスアダプターが設定、接続されている必要があります。設定/接続がされている場合には
hosted-engine
により、利用可能な LUN が自動で検出されます。LUN には既存のデータが含まれないようにする必要があります。The following luns have been found on the requested target: [1] 3514f0c5447600351 30GiB XtremIO XtremApp status: used, paths: 2 active [2] 3514f0c5447600352 30GiB XtremIO XtremApp status: used, paths: 2 active Please select the destination LUN (1, 2) [1]:
環境で使用するストレージドメインとストレージデータセンターの名前を選択します。[ INFO ] Installing on first host Please provide storage domain name. [hosted_storage]: Local storage datacenter name is an internal name and currently will not be shown in engine's admin UI.Please enter local datacenter name [hosted_datacenter]:
ネットワークの設定
このスクリプトは、環境の管理ブリッジとして使用可能なネットワークインターフェースコントローラー (NIC) を検出し、次にファイアウォールの設定を確認して、その設定を Manager 仮想マシンにコンソールで (SPICE または VNC) アクセスできるように変更するかどうかを確認します。ovirt-ha-agent
で使用できる、ping 送信可能なゲートウェイの IP アドレスを提供すると、Manager 仮想マシンを実行するのに適したホストであるかどうかを判断しやすくなります。Please indicate a nic to set rhevm bridge on: (eth1, eth0) [eth1]: iptables was detected on your computer, do you wish setup to configure it? (Yes, No)[Yes]: Please indicate a pingable gateway IP address [X.X.X.X]:
新しい Manager 仮想マシンの設定
このスクリプトにより、新しい Manager の仮想マシンとして設定される仮想マシンが作成されます。ブートデバイス (該当する場合)、インストールメディアのパス名、イメージのエイリアス、CPU タイプ、仮想 CPU の数、ディスクサイズを指定します。Manager の MAC アドレスを指定するか、ランダムに生成された Mac アドレスを適用します。MAC アドレスは、Manager の仮想マシンにオペレーティングシステムをインストール前に DHCP サーバーを更新するのに使用することができます。Manager 仮想マシンの作成に必要なメモリーサイズとコンソールの接続タイプも指定します。Please specify the device to boot the VM from (cdrom, disk, pxe) [cdrom]: Please specify an alias for the Hosted Engine image [hosted_engine]: The following CPU types are supported by this host: - model_Penryn: Intel Penryn Family - model_Conroe: Intel Conroe Family Please specify the CPU type to be used by the VM [model_Penryn]: Please specify the number of virtual CPUs for the VM [Defaults to minimum requirement: 2]: Please specify the disk size of the VM in GB [Defaults to minimum requirement: 25]: You may specify a MAC address for the VM or accept a randomly generated default [00:16:3e:77:b2:a4]: Please specify the memory size of the VM in MB [Defaults to minimum requirement: 4096]: Please specify the console type you want to use to connect to the VM (vnc, spice) [vnc]:
ホスト名の特定
ホスト名には一意の名前を指定して、engine をバックアップから復元した時点で存在する他のリソースと競合しないようにします。本手順では、対象のホストは環境がバックアップされる前にメンテナンスモードに設定され、engine を復元してからホストと engine を同期するまでの間に、このホストを削除することができるため、hosted_engine_1
という名前を使用することができます。Enter the name which will be used to identify this host inside the Administration Portal [hosted_engine_1]:
ホストエンジンの設定
セルフホストエンジン環境の名前と、管理ポータルへアクセスするadmin@internal
ユーザーのパスワードを指定し、新しい Manager 仮想マシンの完全修飾ドメイン名を設定します。本手順では、Manager.example.com という完全修飾ドメイン名を使用します。次に、SMTP サーバーの 名前と TCP ポート番号、メール通知の送信先に使用するメールアドレス、これらの通知を受信するメールアドレス (コンマ区切りの一覧) を指定してください。重要
engine に指定した完全修飾ドメイン名 (Manager.example.com) は、元の Manager の初期設定時に指定した名前と同じ完全修飾ドメイン名でなければなりません。Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: Confirm 'admin@internal' user password: Please provide the FQDN for the engine you would like to use. This needs to match the FQDN that you will use for the engine installation within the VM. Note: This will be the FQDN of the VM you are now going to create, it should not point to the base host or to any other existing machine. Engine FQDN: Manager.example.com Please provide the name of the SMTP server through which we will send notifications [localhost]: Please provide the TCP port number of the SMTP server [25]: Please provide the email address from which notifications will be sent [root@localhost]: Please provide a comma-separated list of email addresses which will get notifications [root@localhost]:
設定のプレビュー
続行する前に、hosted-engine
デプロイメントスクリプトは、入力された設定値を表示して、これらの値で設定を続行するかどうかを尋ねます。Bridge interface : eth1 Engine FQDN : Manager.example.com Bridge name : rhevm SSH daemon port : 22 Firewall manager : iptables Gateway address : X.X.X.X Host name for web application : hosted_engine_1 Host ID : 1 Image alias : hosted_engine Image size GB : 25 Storage connection : storage.example.com:/hosted_engine/nfs Console type : vnc Memory size MB : 4096 MAC address : 00:16:3e:77:b2:a4 Boot type : pxe Number of CPUs : 2 CPU Type : model_Penryn Please confirm installation settings (Yes, No)[Yes]:
新しい Manager 仮想マシンの作成
次にこのスクリプトは、Manager 仮想マシンとして設定する仮想マシンを作成し、接続情報を表示します。hosted-engine
スクリプトがホストエンジンの設定に進む前に、仮想マシンにオペレーティングシステムをインストールする必要があります。[ INFO ] Stage: Transaction setup [ INFO ] Stage: Misc configuration [ INFO ] Stage: Package installation [ INFO ] Stage: Misc configuration [ INFO ] Configuring libvirt [ INFO ] Configuring VDSM [ INFO ] Starting vdsmd [ INFO ] Waiting for VDSM hardware info [ INFO ] Waiting for VDSM hardware info [ INFO ] Configuring the management bridge [ INFO ] Creating Storage Domain [ INFO ] Creating Storage Pool [ INFO ] Connecting Storage Pool [ INFO ] Verifying sanlock lockspace initialization [ INFO ] Creating VM Image [ INFO ] Disconnecting Storage Pool [ INFO ] Start monitoring domain [ INFO ] Configuring VM [ INFO ] Updating hosted-engine configuration [ INFO ] Stage: Transaction commit [ INFO ] Stage: Closing up [ INFO ] Creating VM You can now connect to the VM with the following command: /usr/bin/remote-viewer vnc://localhost:5900 Use temporary password "3477XXAM" to connect to vnc console. Please note that in order to use remote-viewer you need to be able to run graphical applications. This means that if you are using ssh you have to supply the -Y flag (enables trusted X11 forwarding). Otherwise you can run the command from a terminal in your preferred desktop environment. If you cannot run graphical applications you can connect to the graphic console from another host or connect to the console using the following command: virsh -c qemu+tls://Test/system console HostedEngine If you need to reboot the VM you will need to start it manually using the command: hosted-engine --vm-start You can then set a temporary password using the command: hosted-engine --add-console-password The VM has been started. Install the OS and shut down or reboot it. To continue please make a selection: (1) Continue setup - VM installation is complete (2) Reboot the VM and restart installation (3) Abort setup (4) Destroy VM and abort setup (1, 2, 3, 4)[1]:
本手順の命名規則を使用して、以下のコマンドで VNC を使って仮想マシンに接続します。/usr/bin/remote-viewer vnc://hosted_engine_1.example.com:5900
仮想マシンのオペレーティングシステムのインストール
Manager の仮想マシンに接続して、Red Hat Enterprise Linux 6.7 のオペレーティングシステムをインストールします。ホストと Manager の同期
ホストに戻り、オプション 1 を選択してhosted-engine
デプロイメントスクリプトを続行します。(1) Continue setup - VM installation is complete
Waiting for VM to shut down... [ INFO ] Creating VM You can now connect to the VM with the following command: /usr/bin/remote-viewer vnc://localhost:5900 Use temporary password "3477XXAM" to connect to vnc console. Please note that in order to use remote-viewer you need to be able to run graphical applications. This means that if you are using ssh you have to supply the -Y flag (enables trusted X11 forwarding). Otherwise you can run the command from a terminal in your preferred desktop environment. If you cannot run graphical applications you can connect to the graphic console from another host or connect to the console using the following command: virsh -c qemu+tls://Test/system console HostedEngine If you need to reboot the VM you will need to start it manually using the command: hosted-engine --vm-start You can then set a temporary password using the command: hosted-engine --add-console-password Please install and setup the engine in the VM. You may also be interested in subscribing to "agent" RHN/Satellite channel and installing rhevm-guest-agent-common package in the VM. To continue make a selection from the options below: (1) Continue setup - engine installation is complete (2) Power off and restart the VM (3) Abort setup (4) Destroy VM and abort setup (1, 2, 3, 4)[1]:
Manager のインストール
新しい Manager の仮想マシンに接続し、インストールしたパッケージがすべて最新版を使用していることを確認してから、rhevm パッケージをインストールします。# yum update
# yum install rhevm
Reports および Data Warehouse のインストール
Reports および Data Warehouse を復元する場合には、rhevm-reports-setup と rhevm-dwh-setup パッケージをインストールします。# yum install rhevm-reports-setup rhevm-dwh-setup
6.4. セルフホストエンジン Manager の復元
engine-backup
ツールを使用して、バックアップしたセルフホストエンジンの Manager 仮想マシン、Reports、Data Warehouseの構成設定とデータベースコンテンツを自動的に復元する方法を説明します。この手順は、engine-setup
の初回実行時に自動的に設定したコンポーネントのみが対象です。engine-setup
時にデータベースを手動で設定した場合は、「セルフホストエンジン Manager の手動での復元」の説明に従い、バックアップ環境を手動で復元してください。
手順6.3 セルフホストエンジン Manager の復元
- バックアップファイルを新しい Manager 仮想マシンにセキュアコピーします。この例では、「セルフホストエンジンの Manager 仮想マシンのバックアップ」でファイルをコピーしたネットワークストレージサーバーからファイルをコピーします。このコマンドで、Storage.example.com はストレージサーバーの完全修飾ドメイン名、/backup/EngineBackupFiles はストレージサーバーのバックアップファイルへの指定ファイルパス、/backup/ は新規 Manager 上にバックアップファイルをコピーするファイルへのパスに置き換えます。
# scp -p Storage.example.com:/backup/EngineBackupFiles /backup/
engine-backup
ツールを使用して完全なバックアップを復元します。- Manager のみを復元する場合は、以下を実行します。
# engine-backup --mode=restore --file=file_name --log=log_file_name --provision-db
- Manager、Reports、Data Warehouse を復元する場合には、以下を実行します。
# engine-backup --mode=restore --file=file_name --log=log_file_name --provision-db --provision-dwh-db --provision-reports-db
正常に終了すると、以下のような出力が表示されます。You should now run engine-setup. Done.
- 復元した Manager 仮想マシンを設定します。このプロセスにより、既存の構成設定およびデータベースの内容が特定されますので、設定を確認してください。完了すると、この設定で SSH フィンガープリントと内部の証明局のハッシュが提供されます。
# engine-setup
[ INFO ] Stage: Initializing [ INFO ] Stage: Environment setup Configuration files: ['/etc/ovirt-engine-setup.conf.d/10-packaging.conf', '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf'] Log file: /var/log/ovirt-engine/setup/ovirt-engine-setup-20140304075238.log Version: otopi-1.1.2 (otopi-1.1.2-1.el6ev) [ INFO ] Stage: Environment packages setup [ INFO ] Yum Downloading: rhel-65-zstream/primary_db 2.8 M(70%) [ INFO ] Stage: Programs detection [ INFO ] Stage: Environment setup [ INFO ] Stage: Environment customization --== PACKAGES ==-- [ INFO ] Checking for product updates... [ INFO ] No product updates found --== NETWORK CONFIGURATION ==-- Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]: [ INFO ] iptables will be configured as firewall manager. --== DATABASE CONFIGURATION ==-- --== OVIRT ENGINE CONFIGURATION ==-- Skipping storing options as database already prepared --== PKI CONFIGURATION ==-- PKI is already configured --== APACHE CONFIGURATION ==-- --== SYSTEM CONFIGURATION ==-- --== END OF CONFIGURATION ==-- [ INFO ] Stage: Setup validation [ INFO ] Cleaning stale zombie tasks --== CONFIGURATION PREVIEW ==-- Database name : engine Database secured connection : False Database host : X.X.X.X Database user name : engine Database host name validation : False Database port : 5432 NFS setup : True Firewall manager : iptables Update Firewall : True Configure WebSocket Proxy : True Host FQDN : Manager.example.com NFS mount point : /var/lib/exports/iso Set application as default page : True Configure Apache SSL : True Please confirm installation settings (OK, Cancel) [OK]:
復元した環境からのホストの削除
バックアップしたエンジンに存在しない一意名が指定されている新規ハードウェアに、復元したセルフホストエンジンをデプロイする場合には、このステップは省略してください。このステップは、フェイルオーバーホスト (hosted_engine_1
) でデプロイメントを行う場合にのみ適用されます。このホストは、バックアップ作成時に環境に存在していたため、復元したエンジンにも存在しています。最終的な同期を行う前には、このホストを環境から削除する必要があります。- 管理ポータルにログインします。
- ホスト タブをクリックします。フェイルオーバーホスト
hosted_engine_1
は、バックアップ時に準備したように、仮想負荷のない状態でメンテナンスモードに入っているはずです。 - 削除 をクリックします。
- OK をクリックします。
注記
削除するホストが non-operational になった場合には、「復元したセルフホストエンジン環境からの非稼働状態のホストの削除」から、ホストの強制削除の方法を参照してください。ホストと Manager の同期
ホストに戻り、オプション 1 を選択してhosted-engine
デプロイメントスクリプトを続行します。(1) Continue setup - engine installation is complete
[ INFO ] Engine replied: DB Up!Welcome to Health Status! [ INFO ] Waiting for the host to become operational in the engine. This may take several minutes... [ INFO ] Still waiting for VDSM host to become operational...
この時点でhosted_engine_1
は管理ポータルに表示されますが、ステータスは Installing および Initializing を経てから Non Operational に切り替わります。ホストは、VDSM ホストが稼動状態になるまで待機し続けますが、最終的に VDSM ホストはタイムアウトになります。これは、環境内の別のホストが Storage Pool Manager (SPM) ロールを維持しており、SPM ホストが Non Responsive の状態にあるためhosted_engine_1
がストレージドメインと対話できなくなるのが原因です。このプロセスがタイムアウトすると、仮想マシンをシャットダウンしてデプロイメントを完了するようにプロンプトが表示されます。デプロイメントが完了したら、ホストを手動でメンテナンスモードに指定して、管理ポータルからアクティブ化することができます。[ INFO ] Still waiting for VDSM host to become operational... [ ERROR ] Timed out while waiting for host to start. Please check the logs. [ ERROR ] Unable to add hosted_engine_2 to the manager Please shutdown the VM allowing the system to launch it as a monitored service. The system will wait until the VM is down.
- 新しい Manager 仮想マシンをシャットダウンします。
# shutdown -h now
- ホストに戻り、Manager 仮想マシンのリブートが検出されていることを確認します。
[ INFO ] Enabling and starting HA services Hosted Engine successfully set up [ INFO ] Stage: Clean up [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination
- ホストをアクティブ化します。
- 管理ポータルにログインします。
- ホストタブをクリックします。
hosted_engine_1
を選択して、メンテナンス ボタンをクリックします。ホストがメンテナンスモードに入るまで、数分かかる場合があります。- アクティブ化 ボタンをクリックします。
アクティブ化の後には、hosted_engine_1
はアクティブ化されると即時に SPM の候補となり、ストレージドメインとデータセンターがアクティブになります。 - Non Responsive なホストを手動でフェンシングして、仮想マシンをアクティブなホストに移行します。管理ポータルで、対象のホストを右クリックして、ホストがリブートされていることを確認 を選択します。バックアップ時にホストで実行中だった仮想マシンは、この時点でホストから削除され、Unknown から Down のステータスに切り替わります。これらの仮想マシンは、
hosted_engine_1
で実行できるようになりました。フェンスされたホストは、REST API を使用して強制的に削除することができます。
hosted_engine_1
がアクティブな時点に環境が復元され、復元した環境で仮想マシンを実行できるようになりました。ステータスが Non Operational となっている残りのセルフホストエンジンホストは、削除してから環境内に再インストールすることが可能です。
6.5. セルフホストエンジン Manager の手動での復元
手順6.4 セルフホストエンジン Manager の復元
- バックアップに含まれるデータベースのコンテンツの復元先となる、空のデータベースを手動で作成します。以下の手順は、データベースがホストされるマシンで実行する必要があります。
- データベースが Manager 仮想マシン以外のマシンでホストされている場合は、postgresql-server パッケージをインストールする必要があります。データベースが Manager 仮想マシンでホストされている場合には、rhevm パッケージにこのパッケージが含まれているため、このステップは必要ありません。
# yum install postgresql-server
postgresql
データベースを初期化し、postgresql
サービスを起動してから、このサービスがブート時に起動されるように設定します。# service postgresql initdb # service postgresql start # chkconfig postgresql on
- postgresql のコマンドラインに入ります。
# su postgres $ psql
engine
ユーザーを作成します。postgres=# create role engine with login encrypted password 'password';
Reports および Data Warehouse も復元する場合には、対象のホストでovirt_engine_reports
およびovirt_engine_history
のユーザーを作成します。postgres=# create role ovirt_engine_reports with login encrypted password 'password';
postgres=# create role ovirt_engine_history with login encrypted password 'password';
- 新規データベースを作成します。
postgres=# create database database_name owner engine template template0 encoding 'UTF8' lc_collate 'en_US.UTF-8' lc_ctype 'en_US.UTF-8';
Reports および Data Warehouse も復元する場合には、対象のホストでデータベースを作成します。postgres=# create database database_name owner ovirt_engine_reports template template0 encoding 'UTF8' lc_collate 'en_US.UTF-8' lc_ctype 'en_US.UTF-8';
postgres=# create database database_name owner ovirt_engine_history template template0 encoding 'UTF8' lc_collate 'en_US.UTF-8' lc_ctype 'en_US.UTF-8';
- postgresql コマンドラインを終了して、postgres ユーザーからログアウトします。
postgres=# \q $ exit
/var/lib/pgsql/data/pg_hba.conf
ファイルを以下のように編集します。- ローカルデータベースごとに、ファイルの最下部の
Local
で開始するセクションに記載されている既存のディレクティブを以下のディレクティブに置き換えます。host database_name user_name 0.0.0.0/0 md5 host database_name user_name ::0/0 md5
- リモートデータベースごとに、以下のように設定します。
- ファイルの最下部にある
Local
で始まる行の直下に次の行を追記します。X.X.X.X は Manager の IP アドレスに置き換えてください。host database_name user_name X.X.X.X/32 md5
- データベースへの TCP/IP 接続を許可します。
/var/lib/pgsql/data/pg_hba.conf
ファイルを編集して、以下の行を追加します。listen_addresses='*'
上記の例では、全インターフェースの接続をリッスンするようにpostgresql
を設定しています。IP アドレスを指定して、特定のインターフェースをリッスンするように設定することもできます。 - PostgreSQL データベースの接続に使用するデフォルトのポートを開放して、更新したファイアウォールルールを保存します。
# iptables -I INPUT 5 -p tcp -s Manager_IP_Address --dport 5432 -j ACCEPT # service iptables save
postgresql
サービスを再起動します。# service postgresql restart
- バックアップファイルを新しい Manager 仮想マシンにセキュアコピーします。この例では、「セルフホストエンジンの Manager 仮想マシンのバックアップ」でファイルをコピーしたネットワークストレージサーバーからファイルをコピーします。このコマンドで、Storage.example.com はストレージサーバーの完全修飾ドメイン名、/backup/EngineBackupFiles はストレージサーバーのバックアップファイルへの指定ファイルパス、/backup/ は新規 Manager 上にバックアップファイルをコピーするファイルへのパスに置き換えます。
# scp -p Storage.example.com:/backup/EngineBackupFiles /backup/
--change-db-credentials
パラメーターを使用して新規データベースの認証情報を渡し、完全なバックアップまたはデータベースのみのバックアップを復元します。Manager のローカルに設定されているデータベースの database_location はlocalhost
です。注記
以下の例では、パスワードは指定せずに、各データベースに--*password
オプションを使用するため、このコマンドを実行すると、データベースごとにパスワードを入力するように要求されます。コマンド内でこれらのオプションにパスワードを指定することも可能ですが、パスワードが shell の履歴に保存されてしまうため推奨しません。別の方法として、各データベースに--*passfile=
password_file オプションを使用して、対話型プロンプトの必要なくパスワードをセキュアにengine-backup
ツールに渡すことができます。- 完全なバックアップを復元する場合:
# engine-backup --mode=restore --file=file_name --log=log_file_name --change-db-credentials --db-host=database_location --db-name=database_name --db-user=engine --db-password
Reports および Data Warehouse も全バックアップの一部として復元する場合には、両データベースの変更後の認証情報を含めるようにしてください。engine-backup --mode=restore --file=file_name --log=log_file_name --change-db-credentials --db-host=database_location --db-name=database_name --db-user=engine --db-password --change-reports-db-credentials --reports-db-host=database_location --reports-db-name=database_name --reports-db-user=ovirt_engine_reports --reports-db-password --change-dwh-db-credentials --dwh-db-host=database_location --dwh-db-name=database_name --dwh-db-user=ovirt_engine_history --dwh-db-password
- データベースのみのバックアップを復元する場合 (設定ファイルのバックアップを最初に復元してからデータベースのバックアップを復元):
# engine-backup --mode=restore --scope=files --file=file_name --log=log_file_name
# engine-backup --mode=restore --scope=db --file=file_name --log=file_name --change-db-credentials --db-host=database_location --db-name=database_name --db-user=engine --db-password
上記の例では、Manager データベースのバックアップが復元されます。# engine-backup --mode=restore --scope=reportsdb --file=file_name --log=file_name --change-reports-db-credentials --reports-db-host=database_location --reports-db-name=database_name --reports-db-user=ovirt_engine_reports --reports-db-password
上記の例では、Reports データベースのバックアップが復元されます。# engine-backup --mode=restore --scope=dwhdb --file=file_name --log=file_name --change-dwh-db-credentials --dwh-db-host=database_location --dwh-db-name=database_name --dwh-db-user=ovirt_engine_history --dwh-db-password
上記の例では、Data Warehouse データベースのバックアップが復元されます。
正常に終了すると、以下のような出力が表示されます。You should now run engine-setup. Done.
- 復元した Manager 仮想マシンを設定します。このプロセスにより、既存の構成設定およびデータベースの内容が特定されますので、設定を確認してください。完了すると、この設定で SSH フィンガープリントと内部の証明局のハッシュが提供されます。
# engine-setup
[ INFO ] Stage: Initializing [ INFO ] Stage: Environment setup Configuration files: ['/etc/ovirt-engine-setup.conf.d/10-packaging.conf', '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf'] Log file: /var/log/ovirt-engine/setup/ovirt-engine-setup-20140304075238.log Version: otopi-1.1.2 (otopi-1.1.2-1.el6ev) [ INFO ] Stage: Environment packages setup [ INFO ] Yum Downloading: rhel-65-zstream/primary_db 2.8 M(70%) [ INFO ] Stage: Programs detection [ INFO ] Stage: Environment setup [ INFO ] Stage: Environment customization --== PACKAGES ==-- [ INFO ] Checking for product updates... [ INFO ] No product updates found --== NETWORK CONFIGURATION ==-- Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]: [ INFO ] iptables will be configured as firewall manager. --== DATABASE CONFIGURATION ==-- --== OVIRT ENGINE CONFIGURATION ==-- Skipping storing options as database already prepared --== PKI CONFIGURATION ==-- PKI is already configured --== APACHE CONFIGURATION ==-- --== SYSTEM CONFIGURATION ==-- --== END OF CONFIGURATION ==-- [ INFO ] Stage: Setup validation [ INFO ] Cleaning stale zombie tasks --== CONFIGURATION PREVIEW ==-- Database name : engine Database secured connection : False Database host : X.X.X.X Database user name : engine Database host name validation : False Database port : 5432 NFS setup : True Firewall manager : iptables Update Firewall : True Configure WebSocket Proxy : True Host FQDN : Manager.example.com NFS mount point : /var/lib/exports/iso Set application as default page : True Configure Apache SSL : True Please confirm installation settings (OK, Cancel) [OK]:
復元した環境からのホストの削除
バックアップしたエンジンに存在しない一意名が指定されている新規ハードウェアに、復元したセルフホストエンジンをデプロイする場合には、このステップは省略してください。このステップは、フェイルオーバーホスト (hosted_engine_1
) でデプロイメントを行う場合にのみ適用されます。このホストは、バックアップ作成時に環境に存在していたため、復元したエンジンにも存在しています。最終的な同期を行う前には、このホストを環境から削除する必要があります。- 管理ポータルにログインします。
- ホスト タブをクリックします。フェイルオーバーホスト
hosted_engine_1
は、バックアップ時に準備したように、仮想負荷のない状態でメンテナンスモードに入っているはずです。 - 削除 をクリックします。
- OK をクリックします。
ホストと Manager の同期
ホストに戻り、オプション 1 を選択してhosted-engine
デプロイメントスクリプトを続行します。(1) Continue setup - engine installation is complete
[ INFO ] Engine replied: DB Up!Welcome to Health Status! [ INFO ] Waiting for the host to become operational in the engine. This may take several minutes... [ INFO ] Still waiting for VDSM host to become operational...
この時点でhosted_engine_1
は管理ポータルに表示されますが、ステータスは Installing および Initializing を経てから Non Operational に切り替わります。ホストは、VDSM ホストが稼動状態になるまで待機し続けますが、最終的に VDSM ホストはタイムアウトになります。これは、環境内の別のホストが Storage Pool Manager (SPM) ロールを維持しており、SPM ホストが Non Responsive の状態にあるためhosted_engine_1
がストレージドメインと対話できなくなるのが原因です。このプロセスがタイムアウトすると、仮想マシンをシャットダウンしてデプロイメントを完了するようにプロンプトが表示されます。デプロイメントが完了したら、ホストを手動でメンテナンスモードに指定して、管理ポータルからアクティブ化することができます。[ INFO ] Still waiting for VDSM host to become operational... [ ERROR ] Timed out while waiting for host to start. Please check the logs. [ ERROR ] Unable to add hosted_engine_2 to the manager Please shutdown the VM allowing the system to launch it as a monitored service. The system will wait until the VM is down.
- 新しい Manager 仮想マシンをシャットダウンします。
# shutdown -h now
- ホストに戻り、Manager 仮想マシンのリブートが検出されていることを確認します。
[ INFO ] Enabling and starting HA services Hosted Engine successfully set up [ INFO ] Stage: Clean up [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination
- ホストをアクティブ化します。
- 管理ポータルにログインします。
- ホスト タブをクリックします。
hosted_engine_1
を選択して、メンテナンス ボタンをクリックします。ホストがメンテナンスモードに入るまで、数分かかる場合があります。- アクティブ化 ボタンをクリックします。
アクティブ化の後には、hosted_engine_1
はアクティブ化されると即時に SPM の候補となり、ストレージドメインとデータセンターがアクティブになります。 - Non Responsive なホストを手動でフェンシングして、仮想マシンをアクティブなホストに移行します。管理ポータルで、対象のホストを右クリックして、ホストがリブートされていることを確認 を選択します。バックアップ時にホストで実行中だった仮想マシンは、この時点でホストから削除され、Unknown から Down のステータスに切り替わります。これらの仮想マシンは、
hosted_engine_1
で実行できるようになりました。フェンスされたホストは、REST API を使用して強制的に削除することができます。
hosted_engine_1
がアクティブな時点に環境が復元され、復元した環境で仮想マシンを実行できるようになりました。ステータスが Non Operational となっている残りのセルフホストエンジンホストは、削除してから環境内に再インストールすることが可能です。
6.6. 復元したセルフホストエンジン環境からの非稼働状態のホストの削除
非稼働状態のホストのフェンシング
管理ポータルで、ホストの上で右クリックをして ホストがリブートされていることを確認 を選択します。バックアップ時にホストで実行中だった仮想マシンは、この時点でホストから削除され、Unknown から Down のステータスに切り替わります。フェンスされたホストは、REST API を使用して強制的に削除することができます。Manager の認証局の証明書取得
Manager の仮想マシンに接続して、コマンドラインを使用して cURL で以下の要求を実行します。GET
要求で、今後の API 要求に使用できるようにManager の認証局 (CA) の証明書を取得します。以下の例では、--output
オプションを使用して、Manager CA 証明書の出力先に hosted-engine.ca ファイルを指定します。また、--insecure
オプションは、このような最初の要求は証明書なしで行うように指定します。# curl --output hosted-engine.ca --insecure https://[Manager.example.com]/ca.crt
削除するホストの GUID の取得
一連のホストに対してGET
要求を使用して、削除するホストのグローバル一意識別子 (GUID) を取得します。以下の例では、Manager CA 証明書ファイルを含めます。認証にはadmin@internal
ユーザーを使用し、このユーザーに対するパスワードは、コマンドの実行後に求められます。# curl --request GET --cacert hosted-engine.ca --user admin@internal https://[Manager.example.com]/api/hosts
今回の要求では、環境内の全ホストの情報が返されます。ホストの GUID は、ホスト名が関連付けられた 16 進数の文字列です。Red Hat Enterprise Virtualization REST API についての詳しい情報は、『Red Hat Enterprise Virtualization REST API ガイド』を参照してください。フェンスされたホストの削除
DELETE
要求を使用してフェンスされたホストの GUID を指定し、そのホストを環境から削除します。以前に使用したオプションに加え、以下の例では、拡張マークアップ言語 (XML: eXtensible Markup Language) を使用して要求を送受信するように指定するヘッダーと、force
アクションをtrue
に設定する XML 形式の本文を記述します。curl --request DELETE --cacert hosted-engine.ca --user admin@internal --header "Content-Type: application/xml" --header "Accept: application/xml" --data "<action><force>true</force></action>" https://[Manager.example.com]/api/hosts/ecde42b0-de2f-48fe-aa23-1ebd5196b4a5
適切な GUID が指定されている場合には、このDELETE
要求を使用して、セルフホストエンジン環境にある、フェンスされたホストをすべて削除することができます。
6.7. 復元したセルフホストエンジン環境に追加のホストをインストールする手順
前提条件
- 物理ホストを追加のセルフホストエンジンホストとして使用するための準備をします。新規インストールした Red Hat Enterprise Linux ホストまたは、バックアップした環境のセルフホストエンジンホストを使用できます。新規インストールしたホストを使用する場合は、必要なエンタイトルメントにホストをサブスクライブして、
ovirt-hosted-engine-setup
をインストールします。「必要なエンタイトルメントのサブスクライブ」を参照してください。セルフホストエンジンのホストを再利用する場合は、セルフホストエンジンの設定を削除します。「セルフホストエンジン環境からのホストの削除」を参照してください。
手順6.5 セルフホストエンジンホストの追加
- ovirt-hosted-engine-setup パッケージをインストールします。
# yum install ovirt-hosted-engine-setup
- デプロイメントコマンドでホストを設定します。
# hosted-engine --deploy
ネットワーク経由でhosted-engine
デプロイメントスクリプトを実行する場合には、ネットワークまたはターミナルが中断された際にセッションが失われないようにscreen
ウィンドウマネージャーの使用を推奨しています。screen パッケージがインストールされていない場合には、先にこのパッケージをインストールしてください。# screen hosted-engine --deploy
初期化の準備
このスクリプトは最初に、セルフホストエンジン環境で対象のホストをハイパーバイザーとして使用することについての確認を要求します。Continuing will configure this host for serving as hypervisor and create a VM where you have to install oVirt Engine afterwards. Are you sure you want to continue? (Yes, No)[Yes]:
ストレージの設定
使用するストレージのタイプを選択します。During customization use CTRL-D to abort. Please specify the storage you would like to use (iscsi, nfs3, nfs4)[nfs3]:
- NFS ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/nfs
- iSCSI の場合には、iSCSI ポータルの IP アドレス、ユーザー名、およびパスワードを指定して、自動検出されたリストからターゲット名を選択します。
Please specify the iSCSI portal IP address: Please specify the iSCSI portal port [3260]: Please specify the iSCSI portal user: Please specify the iSCSI portal password: Please specify the target name (auto-detected values) [default]:
セルフホストエンジンの検出
hosted-engine
のスクリプトは、共有ストレージが使用されていることを検出して、追加のホスト設定であるかどうかを確認した後に、プロンプトでホスト ID を要求します。この ID は環境内のホストには割り当てられていない整数を使用する必要があります。The specified storage location already contains a data domain. Is this an additional host setup (Yes, No)[Yes]? [ INFO ] Installing on additional host Please specify the Host ID [Must be integer, default: 2]:
システムの設定
hosted-engine
スクリプトは、最初の hosted-engine 設定で作成された応答ファイルを使用します。これには、hosted-engine スクリプトにより応答ファイルにアクセスして追加ホストにセキュアコピーできるように、FQDN または IP アドレスと、ホストのroot
ユーザーパスワードが必要となります。[WARNING] A configuration file must be supplied to deploy Hosted Engine on an additional host. The answer file may be fetched from the first host using scp. If you do not want to download it automatically you can abort the setup answering no to the following question. Do you want to scp the answer file from the first host? (Yes, No)[Yes]: Please provide the FQDN or IP of the first host: Enter 'root' user password for host [hosted_engine_1.example.com]: [ INFO ] Answer file successfully downloaded
ホストエンジンの設定
Red Hat Enterprise Virtualization 環境で識別できるように、追加ホストの名前とadmin@internal
ユーザーのパスワードを指定します。この名前には、環境内の別のホストが使用していないものを選択する必要があります。Enter the name which will be used to identify this host inside the Administrator Portal [hosted_engine_2]: Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: Confirm 'admin@internal' user password:
設定のプレビュー
続行する前に、hosted-engine
スクリプトは、入力された設定値を表示して、これらの値で設定を続行するかどうかを尋ねます。Bridge interface : eth1 Engine FQDN : HostedEngine-VM.example.com Bridge name : rhevm SSH daemon port : 22 Firewall manager : iptables Gateway address : X.X.X.X Host name for web application : hosted_engine_2 Host ID : 2 Image size GB : 25 Storage connection : storage.example.com:/hosted_engine/nfs Console type : vnc Memory size MB : 4096 MAC address : 00:16:3e:05:95:50 Boot type : disk Number of CPUs : 2 CPU Type : model_Penryn Please confirm installation settings (Yes, No)[Yes]:
engine のインストール完了の確認
スクリプトにより以下の選択肢のプロンプトが表示された後に、追加されたホストが Manager とhosted_engine_1
に問い合わせを行います。[ INFO ] Stage: Closing up To continue make a selection from the options below: (1) Continue setup - engine installation is complete (2) Power off and restart the VM (3) Abort setup (4) Destroy VM and abort setup (1, 2, 3, 4)[1]
[ INFO ] Engine replied: DB Up!Welcome to Health Status! [ INFO ] Waiting for the host to become operational in the engine. This may take several minutes...
この時点でホストは管理ポータルに表示されますが、ステータスは Installing および Initializing を経てから Non Operational に切り替わります。ホストは、VDSM ホストが稼動状態になるまで待機し続けますが、最終的に VDSM ホストはタイムアウトになります。[ INFO ] Still waiting for VDSM host to become operational... [ INFO ] Still waiting for VDSM host to become operational... [ ERROR ] Timed out while waiting for host to start. Please check the logs. [ ERROR ] Unable to add hosted_engine_1 to the manager [ INFO ] Enabling and starting HA services Hosted Engine successfully set up [ INFO ] Stage: Clean up [ INFO ] Generating answer file '/etc/ovirt-hosted-engine/answers.conf' [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination
- ホストをアクティブ化します。
- 管理ポータルにログインします。
- 管理ポータルで ホスト タブをクリックして、アクティブ化するホストを選択します。
- アクティブ化 ボタンをクリックします。
第7章 セルフホスト環境に追加のホストをインストールする手順
hosted-engine
スクリプトを実行すると、共有ストレージドメインが検出され、必要に応じてこのホストを Manager 仮想マシンをホストするフェールオーバーホストとして使用することができます。また、hosted-engine
スクリプトを使用せずに設定した通常のホストも、セルフホストエンジン環境にアタッチできますが、Manager 仮想マシンのホスティング用には使用できません。hosted-engine
で設定されたホストを少なくとも 2 台用意して、Manager 仮想マシンの高可用性を確保することを強く推奨します。
前提条件
- RHEL ベースのセルフホストエンジン環境については、物理ホストに新規インストールされた Red Hat Enterprise Linux システムを用意し、必要なエンタイトルメントにホストをサブスクリプション登録しておく必要があります。サブスクリプションに関する詳しい情報は、「必要なエンタイトルメントのサブスクライブ」を参照してください。
- RHEV-H ベースのセルフホストエンジン環境については、物理ホストに新規インストールされた RHEV-H を用意しておく必要があります。また、少なくともネットワークカードが 1 つ以上設定されており、SSH パスワード認証が Security の画面から有効化されているようにしてください。
手順7.1 別のセルフホストエンジンホストの追加
host-engine スクリプトの起動
- RHEL ベースのセルフホストエンジンのホストの場合は、ovirt-hosted-engine-setup パッケージをインストールして、以下のデプロイメントコマンドを実行します。
# yum install ovirt-hosted-engine-setup
# hosted-engine --deploy
- RHEV-H ベースのセルフホストエンジンのホストの場合は、テキストユーザーインターフェースで Hosted Engine 画面から < Deploy Hosted Engine > を選択して、< Add this host to an existing group > を選び < Deploy > で Enter を押します。
ストレージの設定
使用するストレージのタイプを選択します。During customization use CTRL-D to abort. Please specify the storage you would like to use (iscsi, nfs3, nfs4)[nfs3]:
- NFS ストレージタイプの場合には、完全修飾ドメイン名または IP アドレスを使用した完全なアドレスと、共有ストレージドメインのパス名を指定します。
Please specify the full shared storage connection path to use (example: host:/path): storage.example.com:/hosted_engine/nfs
- iSCSI の場合には、iSCSI ポータルの IP アドレス、ユーザー名、およびパスワードを指定して、自動検出されたリストからターゲット名を選択します。
Please specify the iSCSI portal IP address: Please specify the iSCSI portal port [3260]: Please specify the iSCSI portal user: Please specify the iSCSI portal password: Please specify the target name (auto-detected values) [default]:
セルフホストエンジンの検出
hosted-engine
のスクリプトは、共有ストレージが使用されていることを検出して、追加のホスト設定であるかどうかを確認した後に、プロンプトでホスト ID を要求します。この ID は環境内の別のホストには割り当てられていない整数を使用する必要があります。The specified storage location already contains a data domain. Is this an additional host setup (Yes, No)[Yes]? [ INFO ] Installing on additional host Please specify the Host ID [Must be integer, default: 2]:
システムの設定
hosted-engine
スクリプトは、最初の hosted-engine 設定で作成された応答ファイルを使用します。これには、hosted-engine スクリプトにより応答ファイルにアクセスして追加ホストにセキュアコピーできるように、FQDN または IP アドレスと、ホストのroot
ユーザーパスワードが必要となります。[WARNING] A configuration file must be supplied to deploy Hosted Engine on an additional host. The answer file may be fetched from the first host using scp. If you do not want to download it automatically you can abort the setup answering no to the following question. Do you want to scp the answer file from the first host? (Yes, No)[Yes]: Please provide the FQDN or IP of the first host: Enter 'root' user password for host Host-HE1.example.com: [ INFO ] Answer file successfully downloaded
ホストエンジンの設定
Red Hat Enterprise Virtualization 環境で識別できるように、追加ホストの名前とadmin@internal
ユーザーのパスワードを指定します。Enter the name which will be used to identify this host inside the Administrator Portal [hosted_engine_2]: Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: Confirm 'admin@internal' user password:
設定のプレビュー
続行する前に、hosted-engine
スクリプトは、入力された設定値を表示して、これらの値で設定を続行するかどうかを尋ねます。Bridge interface : eth1 Engine FQDN : HostedEngine-VM.example.com Bridge name : rhevm SSH daemon port : 22 Firewall manager : iptables Gateway address : X.X.X.X Host name for web application : hosted_engine_2 Host ID : 2 Image size GB : 25 Storage connection : storage.example.com:/hosted_engine/nfs Console type : vnc Memory size MB : 4096 MAC address : 00:16:3e:05:95:50 Boot type : disk Number of CPUs : 2 CPU Type : model_Penryn Please confirm installation settings (Yes, No)[Yes]:
第8章 データベースの移行
8.1. セルフホストエンジンのデータベースをリモートサーバーのデータベースへ移行する手順
engine
データベースをリモートのデータベースサーバーに移行することができます。
pg_dump
および pg_restore
コマンドを使用してデータベースのバックアップと復元を処理します。そのため、/etc/ovirt-engine/engine.conf.d/10-setup-database.conf
ファイルを編集して情報を更新する必要があります。少なくとも、新規データベースサーバーの場所を更新してください。新規データベースサーバーのデータベース名、ロール名、またはパスワードが更新されている場合には、これらの値も 10-setup-database.conf
ファイルで更新する必要があります。以下の手順では、このファイルの変更を最小限に抑えるために、デフォルトの engine
データベースの設定を使用しています。
手順8.1 Red Hat Enterprise Virtualization Manager で使用するためのリモートの PostgreSQL データベースの準備
- リモートのデータベースサーバーにログインして、PostgreSQL サーバーパッケージをインストールします。
# yum install postgresql-server
- PostgreSQL データベースを初期化し、
postgresql
サービスを起動してブート時に起動されるように設定します。# service postgresql initdb # service postgresql start # chkconfig postgresql on
postgres
ユーザーとして、psql コマンドラインインターフェースに接続します。# su - postgres $ psql
- データベースの読み取り/書き込み時に使用する Manager のユーザーを作成します。Manager のデフォルトユーザー名は
engine
です。postgres=# create role user_name with login encrypted password 'password';
注記
engine
ユーザーのパスワードは、/etc/ovirt-engine/engine.conf.d/10-setup-database.conf
にプレーンテキストで保存されています。新規サーバーでロールを作成する際にどのようなパスワードを指定することも可能ですが、別のパスワードを使用した場合には、新しいパスワードに変更して、このファイルを更新してください。 - Red Hat Enterprise Virtualization 環境に関するデータを保管するデータベースを作成します。Manager のデフォルトのデータベース名も、デフォルトのユーザー名も
engine
です。postgres=# create database database_name owner user_name template template0 encoding 'UTF8' lc_collate 'en_US.UTF-8' lc_ctype 'en_US.UTF-8';
- md5 クライアントの認証を有効にして、データベースにリモートからアクセスできるようにします。
/var/lib/pgsql/data/pg_hba.conf
ファイルを編集して、ファイルの一番下にあるlocal
で始まる行のすぐ下に以下の行を追加します。X.X.X.X は、お使いの Manager の IP アドレスに置き換えてください。host database_name user_name X.X.X.X/32 md5
- データベースへの TCP/IP 接続を許可します。
/var/lib/pgsql/data/pg_hba.conf
ファイルを編集して、以下の行を追加します。listen_addresses='*'
上記の例では、全インターフェースの接続をリッスンするようにpostgresql
を設定しています。IP アドレスを指定して、特定のインターフェースをリッスンするように設定することもできます。 - PostgreSQL データベース接続に使用するデフォルトのポートを開放して、更新したファイアウォールルールを保存します。
# iptables -I INPUT 5 -p tcp --dport 5432 -j ACCEPT # service iptables save
postgresql
サービスを再起動します。# service postgresql restart
手順8.2 データベースの移行
- ホストエンジンホストの 1 つにログインして、環境を
global
メンテナンスモードに指定します。これにより、高可用性のエージェントを無効化して、この手順の実行中に Manager 仮想マシンが移行されないようにします。# hosted-engine --set-maintenance --mode=global
- Manager 仮想マシンにログインし、engine のバックアップを干渉しないように
ovirt-engine
サービスを停止します。# service ovirt-engine stop
- PostgreSQL
pg_dump
コマンドを使用して、engine
データベースのバックアップを作成します。# su - postgres -c 'pg_dump -F c engine -f /tmp/engine.dump'
- バックアップファイルを新規データベースサーバーにコピーします。ターゲットのディレクトリーでは、
postgres
ユーザーの書き込みアクセスを許可しておく必要があります。# scp /tmp/engine.dump root@new.database.server.com:/tmp/engine.dump
- 新しいデータベースサーバーにログインして、PostgreSQL の
pg_restore
コマンドを使用してデータベースを復元します。# su - postgres -c 'pg_restore -d engine /tmp/engine.dump'
- Manager 仮想マシンにログインして
/etc/ovirt-engine/engine.conf.d/10-setup-database.conf
を更新します。ENGINE_DB_HOST
のlocalhost
の値は、新規データベースサーバーの IP アドレスに置き換えます。新規データベースサーバーのエンジン名、ロール名、パスワードが異なる場合は、このファイルでこれらの値を更新してください。 - データベースが移行されたので、
ovirt-engine
サービスを起動します。# service ovirt-engine start
- ホストエンジンのホストにログインして、メンテナンスモードをオフにして、高可用性エージェントを有効にします。
# hosted-engine --set-maintenance --mode=none
8.2. Data Warehouse と Reports を別のマシンに移行する方法
ovirt_engine_history
データベースと接続します。またはオプションで、ovirt_engine_history
データベースを新規データベースマシンに移行してから、Data Warehouse サービスを移行します。ovirt_engine_history
データベースが Manager でホストされている場合には、Data Warehouse サービスとこのデータベースを移行して、Manager マシン上でのリソースの競合をさらに軽減することができます。データベースは、Data Warehouse サービスの移行先と同じマシンに移行することが可能です。また、Manager マシンや新規 Data Warehouse サービス用のマシンとは別のマシンに移行することもできます。
8.3. Data Warehouse の別のマシンへの移行
ovirt_engine_history
データベースを移行してから、Data Warehouse サービスを移行します。以下の手順では、 pg_dump
でデータベースのバックアップを作成し、 psql
で新規データベースマシンにバックアップを復元します。pg_dump
コマンドは、データベースをバックアップ/復元するための柔軟なオプションを提供します。お使いのシステムに適したオプションについての情報は、pg_dump
のマニュアルページを参照してください。
重要
engine-setup
を実行して、プロンプトが表示されたら、新規 Data Warehouse のデータベースの詳細を入力し、サービスの再設定を行う必要があります。再設定を行わないと、Reports サービスは以前のデータベースに接続されたままとなり、新規データは受信されません。
手順8.3 Data Warehouse の別のマシンへの移行
- 既存のデータベースマシン上で、
ovirt_engine_history
データベースを SQL スクリプトファイルにダンプします。# pg_dump ovirt_engine_history > ovirt_engine_history.sql
- 既存のデータベースマシンから新規データベースマシンに、このスクリプトファイルをコピーします。
- 新規データベースマシン上で
ovirt_engine_history
データベースを復元します。# psql -d ovirt_engine_history -f ovirt_engine_history.sql
上記のコマンドは、新規マシン上のデータベースがovirt_engine_history
という名前であることを前提としています。
8.4. Data Warehouse サービスの別のマシンへの移行
ovirt_engine_history
データベース) を移行する方法については、「Data Warehouse の別のマシンへの移行」を参照してください。
- 新規 Data Warehouse マシンの設定
- Manager マシン上の Data Warehouse サービスの停止
- 新規 Data Warehouse マシンの構成
- Manager マシンからの Data Warehouse パッケージの削除
以下の前提条件が満たされていることを確認してください。
- Manager と Data Warehouse は同じマシン上にインストール/設定しておく必要があります。
- 新しい Data Warehouse のマシンを設定するには、以下が必要です。
- Red Hat Enterprise Linux 6.6 または 6.7 をインストール済みの仮想マシンまたは物理マシン
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のエンタイトルメントプールのサブスクリプション- Manager の
/etc/ovirt-engine/engine.conf.d/10-setup-database.conf
ファイルに記載されているパスワード - Data Warehouse のマシンから Manager データベースのマシンの TCP ポート 5432 へのアクセスの許可
- Manager の
/etc/ovirt-engine-dwh/ovirt-engine-dwhd.conf.d/10-setup-database.conf
ファイルからのovirt_engine_history
データベースの認証情報。「Data Warehouse の別のマシンへの移行」の手順に従ってovirt_engine_history
データベースを移行した場合には、そのマシン上でデータベースの設定中に定義した認証情報を取得します。
手順8.4 ステップ 1: 新規 Data Warehouse マシンの設定
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルのユーザー名とパスワードを入力します。
# subscription-manager register
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールを見つけて、プール ID を書き留めておきます。# subscription-manager list --available
- 上記のステップで特定したプール ID を使用して、エンタイトルメントをシステムにアタッチします。
# subscription-manager attach --pool=pool_id
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- 必要なチャンネルを有効にします。
# subscription-manager repos --enable=rhel-6-server-rpms # subscription-manager repos --enable=rhel-6-server-supplementary-rpms # subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms # subscription-manager repos --enable=jb-eap-6-for-rhel-6-server-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
- rhevm-dwh-setup パッケージをインストールします。
# yum install rhevm-dwh-setup
手順8.5 ステップ 2: Manager マシン上での Data Warehouse の停止
- Data Warehouse サービスを停止します。
# service ovirt-engine-dwhd stop
ovirt_engine_history
データベース、Manager データベース、または両データベースが Manager マシンでホストされており、以前のバージョン (Red Hat Enterprise Virtualization 3.4 以前) で設定された後にアップグレードされている場合には、新規 Data Warehouse マシンがこれらのデータベースにアクセスできるようにする必要があります。/var/lib/pgsql/data/postgresql.conf
ファイルを編集して、以下のようになるようにlisten_addresses
の行を変更します。listen_addresses = '*'
この行が存在しない場合やコメントアウトされている場合には、手動で追加します。1 つまたは両データベースがリモートマシンでホストされている場合には、各マシンでpostgres.conf
ファイルを編集して、上記のようにpostgres.conf
の行を追加し、手動でアクセスを許可する必要があります。両データベースが Manager マシンでホストされており、Red Hat Enterprise Virtualization Manager 3.5 の新規セットアップで設定された場合には、デフォルトでアクセスが許可されています。- postgresql サービスを再起動します。
# service postgresql restart
手順8.6 ステップ 3: 新規 Data Warehouse マシンの構成
engine-setup
コマンドを実行し、そのマシン上で Data Warehouse の設定を開始します。# engine-setup
- Enter を押して Data Warehouse を設定します。
Configure Data Warehouse on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Enter を押して自動検出されたホスト名を受け入れるか、別のホスト名を入力して Enter を押します。
Host fully qualified DNS name of this server [autodetected host name]:
ovirt_engine_history
データベースの場所に関する以下の質問に回答します。Where is the DWH database located? (Local, Remote) [Local]: Remote
上記のようにもう一方のオプションを入力して Enter を押します。ovirt_engine_history
データベースのホストの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。DWH database host []: dwh-db-fqdn DWH database port [5432]: DWH database secured connection (Yes, No) [No]: DWH database name [ovirt_engine_history]: DWH database user [ovirt_engine_history]: DWH database password: password
- Manager のデータベースマシンの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。
Engine database host []: engine-db-fqdn Engine database port [5432]: Engine database secured connection (Yes, No) [No]: Engine database name [engine]: Engine database user [engine]: Engine database password: password
- Enter を押して既存の Data Warehouse データベースのバックアップを作成します。
Would you like to backup the existing database before upgrading it? (Yes, No) [Yes]:
データベースのバックアップに必要な時間と領域は、そのデータベースのサイズにより異なります。完了まで数時間かかる場合もあります。ここでデータベースのバックアップを行わず、何らかの理由でengine-setup
が失敗した場合には、データベースまたはその中のデータを復元できません。バックアップファイルの場所は、設定スクリプトの最後に表示されます。 - Manager から既存の Data Warehouse サービスを完全に切断することを確定します。
Do you want to permanently disconnect this DWH from the engine? (Yes, No) [No]:
- インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
手順8.7 ステップ 4: Manager マシンからの Data Warehouse パッケージの削除
- Data Warehouse パッケージを削除します。
# yum remove rhevm-dwh
この手順は、Data Warehouse サービスが自動的に 1 時間後に再起動を試みないようにします。 - Data Warehouse ファイルを削除します。
# rm -rf /etc/ovirt-engine-dwh /var/lib/ovirt-engine-dwh
8.5. 別のマシンへの Reports サービスの移行
ovirt_engine_reports
データベース) は移行することができません。そのため、新規マシンで Reports を設定する際には、新しい ovirt_engine_reports
データベースを作成する必要があります。保存したアドホックレポートは、Manager マシンから新しい Reports マシンに移行することができます。Manager と Data Warehouse を設定してからでないと、Reports サービスの移行はできません。
- 新規 Reports マシンを設定します。
- 保存してあるレポートを新規 Reports マシンに移行します。
- Manager マシンから Reports サービスを削除します。
以下の前提条件が満たされていることを確認してください。
- Manager と Reports は同じマシン上にインストール/設定しておく必要があります。
- Manager マシンまたは別のマシンで、Data Warehouse のインストール/設定が完了している必要があります。
- 新しい Reports マシンを設定するには、以下が必要です。
- Red Hat Enterprise Linux 6.6 または 6.7 をインストール済みの仮想マシンまたは物理マシン
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のエンタイトルメントプールのサブスクリプション- Data Warehouse のマシンの
/etc/ovirt-engine-dwh/ovirt-engine-dwhd.conf.d/10-setup-database.conf
ファイルに記載されているパスワード - Reports のマシンから Manager データベースのマシンの TCP ポート 5432 へのアクセスの許可
手順8.8 ステップ 1: 新規 Reports マシンの構成
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルのユーザー名とパスワードを入力します。
# subscription-manager register
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールを見つけて、プール ID を書き留めておきます。# subscription-manager list --available
- 上記のステップで特定したプール ID を使用して、エンタイトルメントをシステムにアタッチします。
# subscription-manager attach --pool=pool_id
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- 必要なチャンネルを有効にします。
# subscription-manager repos --enable=rhel-6-server-rpms # subscription-manager repos --enable=rhel-6-server-supplementary-rpms # subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms # subscription-manager repos --enable=jb-eap-6-for-rhel-6-server-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
- rhevm-reports-setup パッケージをインストールします。
# yum install rhevm-reports-setup
engine-setup
コマンドを実行し、そのマシン上で Reports の設定を開始します。# engine-setup
- Enter を押して Reports を設定します。
Configure Reports on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Enter を押して自動検出されたホスト名を受け入れるか、別のホスト名を入力して Enter を押します。
Host fully qualified DNS name of this server [autodetected host name]:
- Manager のマシンの完全修飾ドメイン名を入力して Enter を押します。
Host fully qualified DNS name of the engine server []:
ovirt_engine_reports
データベースに関する以下の質問に回答します。Enter を押して、セットアップでローカルのデータベースを作成/設定できるようにします。Where is the Reports database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the Reports to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create Reports database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
ovirt_engine_history
データベースのホストの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。DWH database host []: dwh-db-fqdn DWH database port [5432]: DWH database secured connection (Yes, No) [No]: DWH database name [ovirt_engine_history]: DWH database user [ovirt_engine_history]: DWH database password: password
- Enter を押して、Manager で SSH を介して Reports と Apache の証明書に署名する設定を許可します。
Setup will need to do some actions on the remote engine server. Either automatically, using ssh as root to access it, or you will be prompted to manually perform each such action. Please choose one of the following: 1 - Access remote engine server using ssh as root 2 - Perform each action manually, use files to copy content around (1, 2) [1]:
- Enter を押してデフォルトの SSH ポートを受け入れるか、別のポート番号を入力して Enter を押します。
ssh port on remote engine server [22]:
- Manager のマシンの root パスワードを入力します。
root password on remote engine server manager-fqdn.com:
- Enter を押して Apache 上での SSL の自動設定を許可します。
Setup can configure apache to use SSL using a certificate issued from the internal CA. Do you wish Setup to configure that, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
- Reports の管理ユーザー (
admin
およびsuperuser
) のパスワードを設定します。Reports のシステムは、Manager とは別の独自の認証情報を管理する点に注意してください。Reports power users password:
確認のために、パスワードの再入力を求められます。 - インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
手順8.9 ステップ 2: 保存済みの Reports を新規 Reports マシンへ移行する手順
- Manager マシンで
ovirt-engine-reports-tool
コマンドを実行します。# ovirt-engine-reports-tool
- エクスポートオプションに該当する番号を入力して、Enter を押します。
(2) Export Jasperreports saved reports to a zip file (1, 2, 3) []: 2
- 保存したレポートをエクスポートする ZIP ファイルの絶対パスを入力し、Enter を押します。
/tmp/saved-reports.zip に保存したレポートをエクスポートするファイル名
- zip ファイルを新規 Reports マシンへコピーします。
# scp /tmp/saved-reports.zip reports-machine-fqdn:/tmp/
- 新しい Reports マシンで
ovirt-engine-reports-tool
コマンドを実行します。# ovirt-engine-reports-tool
- インポートオプションに該当する番号を入力して、Enter を押します。
(3) Import a saved reports zip file to Jasperreports (1, 2, 3) []: 3
- インポートする ZIP ファイルの絶対パスを入力して、Enter を押します。
/tmp/saved-reports.zip から保存したレポートをインポートするファイル名
手順8.10 ステップ 3: Manager マシンからの Reports サービスの削除
- Reports サービスを停止します。
# service ovirt-engine-reportsd stop
- Reports パッケージを削除します。
# yum remove rhevm-reports
- Reports ファイルを削除します。
# rm -rf /etc/ovirt-engine-reports /var/lib/ovirt-engine-reports
- Reports のデータベースとユーザーを削除します。両方のデフォルト名は
ovirt_engine_reports
です。# su - postgres $ psql postgres=# drop database ovirt_engine_reports; postgres=# drop user ovirt_engine_reports;
注記
engine-setup
を使用して最後に設定された Reports インスタンスのみとなります。これは、管理ポータルに含まれるのが最新の Reports インストール環境で設定されたダッシュボードだけで、また直接リンクされるのは、最新の Reports インストール環境のみであることを意味します。
第9章 Data Warehouse および Reports
9.1. Data Warehouse と Reports の設定についての概要
ovirt_engine_history
データベースが作成されます。このデータベースに Manager が報告目的で情報をログ記録するように設定されています。Red Hat Enterprise Virtualization Manager Reports の機能は、オプションのコンポーネントとしても利用可能です。Reports は、Java ベースのアプリケーションに埋め込み可能なオープンソースのレポーティングツールである JasperServer および JasperRepots のカスタマイズされた実装を提供します。Reports は Web ユーザーインターフェースでビルド/アクセスが可能なレポートを生成します。これは画面へのレンダリング、印刷が可能なのに加えて、PDF、Excel CSV、Word、RTF、Flash、ODT、ODS などのさまざまな形式でエクスポートすることもできます。Data Warehouse と Reports のコンポーネントはオプションなので、Manager のセットアップに追加でインストールして構成する必要があります。
ovirt_engine_history
データベースが使用する容量およびリソースの推定値を算出するには、RHEV Manager History Database Size Calculator ツールを使用します。この推定値は履歴の記録を保持するように選択したエンティティー数および時間をもとに算出されます。
9.2. Data Warehouse および Reports の設定における注意
engine-setup
では以下のような動作が予想されます。
engine-setup
を実行し、Data Warehouse と Reports の設定は No
と回答します。
Configure Data Warehouse on this host (Yes, No) [Yes]: No Configure Reports on this host (Yes, No) [Yes]: No
engine-setup
を再度実行しても、これらのサービスを設定するオプションは表示されません。
engine-setup
が両オプションを再度表示するように強制するには、engine-setup --reconfigure-optional-components
を実行します。
注記
--offline
のオプションを追加してください。
9.3. Data Warehouse および Reports のインストールオプション
- Manager がインストールされているマシンに Data Warehouse と Reports の両方をインストール/設定する方法
この構成では、Data Warehouse および Reports のサービスを Manager のマシンでホストします。この構成に必要なのは、登録済みのマシン 1 台のみで、最も簡単な構成ですが、サービスが CPU とメモリーを共有する必要があるため、ホストマシンに対する需要が高くなります。Data Warehouse のサービスまたは Reports のサービスへのアクセスが必要なユーザーは、Manager のマシン自体にアクセスする必要があります。
- Manager とは別の 1 台のマシンに Data Warehouse と Reports の両方をインストール/設定する方法
この構成では、Data Warehouse と Reports を Manager とは別の 1 台のマシンでホストします。この構成には、登録済みのマシンが 2 台必要ですが、Manager のマシンの負荷が軽減され、マシン上で CPU とメモリーの共有による競合を回避することができます。管理者は、Manager のマシンへのアクセスを許可する必要なしに、Data Warehouse と Reports がインストールされたマシンへのアクセスをユーザーに許可することができます。Data Warehouse と Reports のサービスは、1 台のホストのリソースをめぐって競うことになる点に注意してください。
- Manager とは別のマシンに Data Warehouse をインストール/設定してから、もう 1 台のマシンに Reports をインストール/設定する方法
この構成では、各サービスが独自のホストに分かれます。この構成には登録済みのマシンが 3 台必要ですが、各マシンへの負荷が軽減され、各サービスは、他のプロセスとの CPU およびメモリーの共有による競合が発生するのを回避することができます。管理者は、特定の 1 台のマシンへのアクセスをユーザーに許可する際に、他の 2 台のマシンへのアクセスを許可する必要はありません。
- Manager のマシンに Data Warehouse をインストール/設定してから、別のマシンに Reports をインストール/設定する方法
この構成では、Data Warehouse は Manager のマシンでホストされ、Reports は別のマシンでホストされます。この構成には登録済みのマシンが 2 台必要ですが、Manager のマシンへの負荷が軽減され、マシン上で メモリーの共有による競合を回避することができます。管理者は、Manager のマシンへのアクセスを許可せずに Reports のマシンへのアクセスをユーザーに許可することができます。
- Manager とは別のマシンに Data Warehouse をインストール/設定してから、Manager のマシンに Reports をインストール/設定する方法
この構成では、Data Warehouse は Manager とは別のマシンでホストされ、Reports は Manager のマシンでホストされます。この構成には、登録済みのマシンが 2 台必要ですが、Manager への負荷が軽減され、メモリーの共有による競合を回避することができます。管理者は、Manager のマシンへのアクセスを許可せずに Data Warehouse のマシンへのアクセスをユーザーに許可することができます。
注記
/usr/share/jasperreports-server-pro/docs/
で参照することができます。
9.3.1. Red Hat Enterprise Virtualization Manager のマシンに Data Warehouse と Reports をインストール/設定する方法
Red Hat Enterprise Virtualization Manager と同じマシンに Data Warehouse と Red Hat Enterprise Virtualization Manager Reports をインストールして設定します。
以下の前提条件が満たされていることを確認してください。
- このマシンで Manager のインストールと設定が完了している必要があります。
- リモートの Data Warehouse データベースまたは Reports データベースを使用するように選択する場合には、Data Warehouse と Reports のサービスをインストールする前に各データベースを設定しておく必要があります。これには、各データベースホストの以下の情報が必要となります。
- ホストの完全修飾ドメイン名
- データベースへの接続に使用するポート (デフォルトでは 5432)
- データベースの名前
- データベースのユーザー
- データベースのパスワード
- セルフホストエンジンを使用している場合には、メンテナンスモードに変更する必要があります。
# hosted-engine --set-maintenance --mode=global
手順9.1 Red Hat Enterprise Virtualization Manager のマシンに Data Warehouse と Reports をインストール/設定する方法
- Red Hat Enterprise Virtualization Manager がインストールされているシステムに rhevm-dwh パッケージと rhevm-reports パッケージをインストールします。
# yum install rhevm-dwh rhevm-reports
engine-setup
コマンドを実行し、そのマシン上で Data Warehouse と Reports の設定を開始します。# engine-setup
- プロンプトに従って Data Warehouse と Reports を設定します。
Configure Data Warehouse on this host (Yes, No) [Yes]: Configure Reports on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Data Warehouse データベースと Reports データベースに関する以下の質問に回答します。
Where is the DWH database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the DWH to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create DWH database, or prefer to perform that manually? (Automatic, Manual) [Automatic]: Where is the Reports database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the Reports to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create Reports database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、各リモートデータベースホストに関する情報を提供するように要求されます。 - Reports の管理ユーザー (
admin
およびsuperuser
) のパスワードを設定します。Reports のシステムは、Manager とは別の独自の認証情報を管理する点に注意してください。Reports power users password:
確認のために、パスワードの再入力を求められます。 - 設定を有効にするには
ovirt-engine
サービスを再起動する必要があります。engine-setup
コマンドは以下のプロンプトを表示します。During execution engine service will be stopped (OK, Cancel) [OK]:
Enter を押して続行します。コマンドの後半にovirt-engine
サービスが再起動します。 - インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
http://demo.redhat.com/ovirt-engine-reports でレポートポータルにアクセスします。demo.redhat.com の箇所は、Manager の完全修飾ドメイン名に置き換えてください。Manager のインストール中にデフォルト以外の HTTP ポートを選択した場合は、URL に :port を追加します。:port を選択したポートに置き換えてください。
admin
というユーザー名と Reports インストール時に設定したパスワードを使用してログインします。Red Hat Enterprise Virtualization Manager Reports への初回ログイン時には、Web ページが複数生成されるため、ログインの完了まで時間がかかる場合があります。
9.3.2. Red Hat Enterprise Virtualization Manager とは別の 1 台のマシンに Data Warehouse と Reports をインストール/設定する方法
Red Hat Enterprise Virtualization Manager がインストールされているマシンとは別の 1 台のホストに Data Warehouse と Red Hat Enterprise Virtualization Manager Reports の両方をインストールして設定します。Data Warehouse サービスおよび Reports サービスを別のマシンでホストすることにより、Manager のマシンの負荷が軽減されます。Data Warehouse と Reports を同じマシンでホストすると、それらのプロセスが CPU とメモリーを共有することになる点に注意してください。
以下の前提条件が満たされていることを確認してください。
- 別のマシンで Manager のインストールと設定が完了している必要があります。
- Data Warehouse と Reports のマシンを設定するには、以下が必要です。
- Red Hat Enterprise Linux 6.6 または 6.7 をインストール済みの仮想マシンまたは物理マシン
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールへのサブスクライブ登録- Manager の
/etc/ovirt-engine/engine.conf.d/10-setup-database.conf
ファイルに記載されているパスワード - Data Warehouse と Reports のマシンから Manager データベースのマシンの TCP ポート 5432 へのアクセスの許可
- リモートの Data Warehouse データベースまたは Reports データベースを使用するように選択する場合には、Data Warehouse と Reports のサービスをインストールする前に各データベースを設定しておく必要があります。これには、各データベースホストの以下の情報が必要となります。
- ホストの完全修飾ドメイン名
- データベースへの接続に使用するポート (デフォルトでは 5432)
- データベースの名前
- データベースのユーザー
- データベースのパスワード
手順9.2 Red Hat Enterprise Virtualization Manager とは別の 1 台のマシンに Data Warehouse と Reports をインストール/設定する方法
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルのユーザー名とパスワードを入力します。
# subscription-manager register
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールを見つけて、プール ID を書き留めておきます。# subscription-manager list --available
- 上記のステップで特定したプール ID を使用して、エンタイトルメントをシステムにアタッチします。
# subscription-manager attach --pool=pool_id
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- 必要なリポジトリーを有効にします。
# subscription-manager repos --enable=rhel-6-server-rpms # subscription-manager repos --enable=rhel-6-server-supplementary-rpms # subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms # subscription-manager repos --enable=jb-eap-6-for-rhel-6-server-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
- rhevm-dwh-setup と rhevm-reports-setup のパッケージをインストールします。
# yum install rhevm-dwh-setup rhevm-reports-setup
engine-setup
コマンドを実行し、そのマシン上で Data Warehouse と Reports の設定を開始します。# engine-setup
- プロンプトに従って Data Warehouse と Reports を設定します。
Configure Data Warehouse on this host (Yes, No) [Yes]: Configure Reports on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Enter を押して自動検出されたホスト名を受け入れるか、別のホスト名を入力して Enter を押します。
Host fully qualified DNS name of this server [autodetected hostname]:
- Manager のマシンの完全修飾ドメイン名を入力して Enter を押します。
Host fully qualified DNS name of the engine server []:
- Data Warehouse データベースと Reports データベースに関する以下の質問に回答します。
Where is the DWH database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the DWH to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create DWH database, or prefer to perform that manually? (Automatic, Manual) [Automatic]: Where is the Reports database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the Reports to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create Reports database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、各リモートデータベースホストに関する情報を提供するように要求されます。 - Manager のデータベースマシンの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。
Engine database host []: engine-db-fqdn Engine database port [5432]: Engine database secured connection (Yes, No) [No]: Engine database name [engine]: Engine database user [engine]: Engine database password: password
- Enter を押して、Manager で SSH を介して Reports と Apache の証明書に署名する設定を許可します。
Setup will need to do some actions on the remote engine server. Either automatically, using ssh as root to access it, or you will be prompted to manually perform each such action. Please choose one of the following: 1 - Access remote engine server using ssh as root 2 - Perform each action manually, use files to copy content around (1, 2) [1]:
- Enter を押してデフォルトの SSH ポートを受け入れるか、別のポート番号を入力して Enter を押します。
ssh port on remote engine server [22]:
- Manager のマシンの root パスワードを入力します。
root password on remote engine server manager-fqdn.com:
- Enter を押して Apache 上での SSL の自動設定を許可します。
Setup can configure apache to use SSL using a certificate issued from the internal CA. Do you wish Setup to configure that, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
- Reports の管理ユーザー (
admin
およびsuperuser
) のパスワードを設定します。Reports のシステムは、Manager とは別の独自の認証情報を管理する点に注意してください。Reports power users password:
確認のために、パスワードの再入力を求められます。 - インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
http://demo.redhat.com/ovirt-engine-reports でレポートポータルにアクセスします。demo.redhat.com の箇所は、Manager の完全修飾ドメイン名に置き換えてください。Manager のインストール中にデフォルト以外の HTTP ポートを選択した場合は、URL に :port を追加します。:port を選択したポートに置き換えてください。
admin
というユーザー名と Reports インストール時に設定したパスワードを使用してログインします。Red Hat Enterprise Virtualization Manager Reports への初回ログイン時には、Web ページが複数生成されるため、ログインの完了まで時間がかかる場合があります。
9.3.3. Red Hat Enterprise Virtualization Manager とは別の 2 台のマシンに Data Warehouse と Reports をインストール/設定する方法
Red Hat Enterprise Virtualization Manager がインストールされているのとは別のホストで Data Warehouse のインストールと設定を行ってから、3 台目のマシンで Red Hat Enterprise Virtualization Manager Reports のインストールと設定を行います。Data Warehouse と Reports のサービスを別のマシンでホストすることにより、Manager のマシンの負荷が軽減されます。また、Data Warehouse と Reports を別々のマシンに分けることにより、各サービスによるホストマシンにへの需要がさらに軽減され、他のプロセスとの CPU およびメモリーの共有による競合を回避することができます。
- Manager とは別のマシンに Data Warehouse をインストールして設定します。
- もう 1 台の別のマシンに Reports をインストールして設定します。
以下の前提条件が満たされていることを確認してください。
- 別のマシンで Manager のインストールと設定が完了している必要があります。
- Data Warehouse のマシンを設定するには、以下が必要です。
- Red Hat Enterprise Linux 6.6 または 6.7 をインストール済みの仮想マシンまたは物理マシン
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールへのサブスクライブ登録- Manager の
/etc/ovirt-engine/engine.conf.d/10-setup-database.conf
ファイルに記載されているパスワード - Data Warehouse のマシンから Manager データベースのマシンの TCP ポート 5432 へのアクセスの許可
- Reports のマシンを設定するには、以下が必要です。
- Red Hat Enterprise Linux 6.6 または 6.7 をインストール済みの仮想マシンまたは物理マシン
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールへのサブスクライブ登録- Data Warehouse のマシンの
/etc/ovirt-engine-dwh/ovirt-engine-dwhd.conf.d/10-setup-database.conf
ファイルに記載されているパスワード - Reports のマシンから Manager データベースのマシンの TCP ポート 5432 へのアクセスの許可
- リモートの Data Warehouse データベースまたは Reports データベースを使用するように選択する場合には、Data Warehouse と Reports のサービスをインストールする前に各データベースを設定しておく必要があります。これには、各データベースホストの以下の情報が必要となります。
- ホストの完全修飾ドメイン名
- データベースへの接続に使用するポート (デフォルトでは 5432)
- データベースの名前
- データベースのユーザー
- データベースのパスワード
手順9.3 ステップ 1: Manager とは別のマシンへの Data Warehouse のインストールおよび設定
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルのユーザー名とパスワードを入力します。
# subscription-manager register
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールを見つけて、プール ID を書き留めておきます。# subscription-manager list --available
- 上記のステップで特定したプール ID を使用して、エンタイトルメントをシステムにアタッチします。
# subscription-manager attach --pool=pool_id
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- 必要なリポジトリーを有効にします。
# subscription-manager repos --enable=rhel-6-server-rpms # subscription-manager repos --enable=rhel-6-server-supplementary-rpms # subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms # subscription-manager repos --enable=jb-eap-6-for-rhel-6-server-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
- rhevm-dwh-setup パッケージをインストールします。
# yum install rhevm-dwh-setup
engine-setup
コマンドを実行し、そのマシン上で Data Warehouse の設定を開始します。# engine-setup
- Enter を押して Data Warehouse を設定します。
Configure Data Warehouse on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Enter を押して自動検出されたホスト名を受け入れるか、別のホスト名を入力して Enter を押します。
Host fully qualified DNS name of this server [autodetected host name]:
- Data Warehouse データベースに関する以下の質問に回答します。
Where is the DWH database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the DWH to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create DWH database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、リモートデータベースホストに関する情報を提供するように要求されます。 - Manager のデータベースマシンの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。
Engine database host []: engine-db-fqdn Engine database port [5432]: Engine database secured connection (Yes, No) [No]: Engine database name [engine]: Engine database user [engine]: Engine database password: password
- インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
手順9.4 ステップ 2: Manager とは別のマシンへの Reports のインストールおよび設定
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルのユーザー名とパスワードを入力します。
# subscription-manager register
- Reports のインストールに必要なリポジトリーが含まれたサブスクリプションプールを特定します。
# subscription-manager list --available | grep -A8 "Red Hat Enterprise Linux Server" # subscription-manager list --available | grep -A8 "Red Hat Enterprise Virtualization"
- 上記のステップで特定したプール ID を使用して、
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のエンタイトルメントをシステムにアタッチします。# subscription-manager attach --pool=pool_id
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- 必要なリポジトリーを有効にします。
# subscription-manager repos --enable=rhel-6-server-rpms # subscription-manager repos --enable=rhel-6-server-supplementary-rpms # subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms # subscription-manager repos --enable=jb-eap-6-for-rhel-6-server-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
- rhevm-reports-setup パッケージをインストールします。
# yum install rhevm-reports-setup
engine-setup
コマンドを実行し、そのマシン上で Reports の設定を開始します。# engine-setup
- Enter を押して Reports を設定します。
Configure Reports on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Enter を押して自動検出されたホスト名を受け入れるか、別のホスト名を入力して Enter を押します。
Host fully qualified DNS name of this server [autodetected host name]:
- Manager のマシンの完全修飾ドメイン名を入力して Enter を押します。
Host fully qualified DNS name of the engine server []:
- Reports データベースに関する以下の質問に回答します。
Where is the Reports database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the Reports to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create Reports database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、リモートデータベースホストに関する情報を提供するように要求されます。 - Data Warehouse データベースのホストの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。
DWH database host []: dwh-db-fqdn DWH database port [5432]: DWH database secured connection (Yes, No) [No]: DWH database name [ovirt_engine_history]: DWH database user [ovirt_engine_history]: DWH database password: password
- Enter を押して、Manager で SSH を介して Reports と Apache の証明書に署名する設定を許可します。
Setup will need to do some actions on the remote engine server. Either automatically, using ssh as root to access it, or you will be prompted to manually perform each such action. Please choose one of the following: 1 - Access remote engine server using ssh as root 2 - Perform each action manually, use files to copy content around (1, 2) [1]:
- Enter を押してデフォルトの SSH ポートを受け入れるか、別のポート番号を入力して Enter を押します。
ssh port on remote engine server [22]:
- Manager のマシンの root パスワードを入力します。
root password on remote engine server manager-fqdn.com:
- Enter を押して Apache 上での SSL の自動設定を許可します。
Setup can configure apache to use SSL using a certificate issued from the internal CA. Do you wish Setup to configure that, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
- Reports の管理ユーザー (
admin
およびsuperuser
) のパスワードを設定します。Reports のシステムは、Manager とは別の独自の認証情報を管理する点に注意してください。Reports power users password:
確認のために、パスワードの再入力を求められます。 - インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
http://demo.redhat.com/ovirt-engine-reports でレポートポータルにアクセスします。demo.redhat.com の箇所は、Manager の完全修飾ドメイン名に置き換えてください。Manager のインストール中にデフォルト以外の HTTP ポートを選択した場合は、URL に :port を追加します。:port を選択したポートに置き換えてください。
admin
というユーザー名と Reports インストール時に設定したパスワードを使用してログインします。Red Hat Enterprise Virtualization Manager Reports への初回ログイン時には、Web ページが複数生成されるため、ログインの完了まで時間がかかる場合があります。
9.3.4. Data Warehouse を Red Hat Enterprise Virtualization Manager のマシンにインストール/設定し、Reports を別のマシンにインストール/設定する方法
Red Hat Enterprise Virtualization Manager と同じシステムで Data Warehouse のインストールと設定を行ってから、別のマシンで Red Hat Enterprise Virtualization Manager Reports のインストールと設定を行います。Reports を別のマシンでホストすることにより、Manager のマシンの負荷が軽減されます。
- Manager のマシンに Data Warehouse をインストールして設定します。
- 別のマシンに Reports をインストールして設定します。
以下の前提条件が満たされていることを確認してください。
- マシンで Manager のインストールと設定が完了している必要があります。これは、Data Warehouse をインストールするマシンです。
- Reports のマシンを設定するには、以下が必要です。
- Red Hat Enterprise Linux 6.6 または 6.7 をインストール済みの仮想マシンまたは物理マシン
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のエンタイトルメントプールのサブスクリプション- Data Warehouse のマシンの
/etc/ovirt-engine-dwh/ovirt-engine-dwhd.conf.d/10-setup-database.conf
ファイルに記載されているパスワード - Reports のマシンから Manager データベースのマシンの TCP ポート 5432 へのアクセスの許可
- リモートの Data Warehouse データベースまたは Reports データベースを使用するように選択する場合には、Data Warehouse と Reports のサービスをインストールする前に各データベースを設定しておく必要があります。これには、各データベースホストの以下の情報が必要となります。
- ホストの完全修飾ドメイン名
- データベースへの接続に使用するポート (デフォルトでは 5432)
- データベースの名前
- データベースのユーザー
- データベースのパスワード
- セルフホストエンジンを使用している場合には、メンテナンスモードに変更する必要があります。
# hosted-engine --set-maintenance --mode=global
手順9.5 ステップ 1: Manager のマシンへの Data Warehouse のインストールおよび設定
- rhevm-dwh パッケージをインストールします。
# yum install rhevm-dwh
engine-setup
コマンドを実行し、そのマシン上で Data Warehouse の設定を開始します。# engine-setup
- Enter を押して Data Warehouse を設定します。
Configure Data Warehouse on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Data Warehouse データベースに関する以下の質問に回答します。
Where is the DWH database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the DWH to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create DWH database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、リモートデータベースホストに関する情報を提供するように要求されます。 - 設定を有効にするには
ovirt-engine
サービスを再起動する必要があります。engine-setup
コマンドは以下のプロンプトを表示します。During execution engine service will be stopped (OK, Cancel) [OK]:
Enter を押して続行します。コマンドの後半にovirt-engine
サービスが再起動します。 - インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
手順9.6 ステップ 2: Manager とは別のマシンへの Reports のインストールおよび設定
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルのユーザー名とパスワードを入力します。
# subscription-manager register
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールを見つけて、プール ID を書き留めておきます。# subscription-manager list --available
- 上記のステップで特定したプール ID を使用して、エンタイトルメントをシステムにアタッチします。
# subscription-manager attach --pool=pool_id
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- 必要なチャンネルを有効にします。
# subscription-manager repos --enable=rhel-6-server-rpms # subscription-manager repos --enable=rhel-6-server-supplementary-rpms # subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms # subscription-manager repos --enable=jb-eap-6-for-rhel-6-server-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
- rhevm-reports-setup パッケージをインストールします。
# yum install rhevm-reports-setup
engine-setup
コマンドを実行し、そのマシン上で Reports の設定を開始します。# engine-setup
- Enter を押して Reports を設定します。
Configure Reports on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Enter を押して自動検出されたホスト名を受け入れるか、別のホスト名を入力して Enter を押します。
Host fully qualified DNS name of this server [autodetected host name]:
- Manager のマシンの完全修飾ドメイン名を入力して Enter を押します。
Host fully qualified DNS name of the engine server []:
- Reports データベースに関する以下の質問に回答します。
Where is the Reports database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the Reports to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create Reports database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、リモートデータベースホストに関する情報を提供するように要求されます。 - Data Warehouse データベースのホストの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。
DWH database host []: dwh-db-fqdn DWH database port [5432]: DWH database secured connection (Yes, No) [No]: DWH database name [ovirt_engine_history]: DWH database user [ovirt_engine_history]: DWH database password: password
- Enter を押して、Manager で SSH を介して Reports と Apache の証明書に署名する設定を許可します。
Setup will need to do some actions on the remote engine server. Either automatically, using ssh as root to access it, or you will be prompted to manually perform each such action. Please choose one of the following: 1 - Access remote engine server using ssh as root 2 - Perform each action manually, use files to copy content around (1, 2) [1]:
- Enter を押してデフォルトの SSH ポートを受け入れるか、別のポート番号を入力して Enter を押します。
ssh port on remote engine server [22]:
- Manager のマシンの root パスワードを入力します。
root password on remote engine server manager-fqdn.com:
- Enter を押して Apache 上での SSL の自動設定を許可します。
Setup can configure apache to use SSL using a certificate issued from the internal CA. Do you wish Setup to configure that, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
- Reports の管理ユーザー (
admin
およびsuperuser
) のパスワードを設定します。Reports のシステムは、Manager とは別の独自の認証情報を管理する点に注意してください。Reports power users password:
確認のために、パスワードの再入力を求められます。 - インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
http://demo.redhat.com/ovirt-engine-reports でレポートポータルにアクセスします。demo.redhat.com の箇所は、Manager の完全修飾ドメイン名に置き換えてください。Manager のインストール中にデフォルト以外の HTTP ポートを選択した場合は、URL に :port を追加します。:port を選択したポートに置き換えてください。
admin
というユーザー名と Reports インストール時に設定したパスワードを使用してログインします。Red Hat Enterprise Virtualization Manager Reports への初回ログイン時には、Web ページが複数生成されるため、ログインの完了まで時間がかかる場合があります。
9.3.5. Data Warehouse を別のマシンにインストール/設定し、Reports を Red Hat Enterprise Virtualization Manager のマシンにインストール/設定する方法
Red Hat Enterprise Virtualization Manager がインストールされているのとは別のホストで Data Warehouse のインストールと設定を行ってから、Manager のマシンで Red Hat Enterprise Virtualization Manager Reports のインストールと設定を行います。Data Warehouse サービスを別のマシンでホストすることにより、Manager のマシンの負荷が軽減されます。Manager と Reports を同じマシンでホストすると、それらのプロセスが CPU とメモリーを共有することになる点に注意してください。
- Manager とは別のマシンに Data Warehouse をインストールして設定します。
- Manager のマシンに Reports をインストールして設定します。
以下の前提条件が満たされていることを確認してください。
- 別のマシンで Manager のインストールと設定が完了している必要があります。
- Data Warehouse のマシンを設定するには、以下が必要です。
- Red Hat Enterprise Linux 6.6 または 6.7 をインストール済みの仮想マシンまたは物理マシン
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のエンタイトルメントプールのサブスクリプション- Manager の
/etc/ovirt-engine/engine.conf.d/10-setup-database.conf
ファイルに記載されているパスワード - Data Warehouse のマシンから Manager データベースのマシンの TCP ポート 5432 へのアクセスの許可
- Reports のマシンを設定するには、以下が必要です。
- Data Warehouse のマシンの
/etc/ovirt-engine-dwh/ovirt-engine-dwhd.conf.d/10-setup-database.conf
ファイルに記載されているパスワード
- リモートの Data Warehouse データベースまたは Reports データベースを使用するように選択する場合には、Data Warehouse と Reports のサービスをインストールする前に各データベースを設定しておく必要があります。これには、各データベースホストの以下の情報が必要となります。
- ホストの完全修飾ドメイン名
- データベースへの接続に使用するポート (デフォルトでは 5432)
- データベースの名前
- データベースのユーザー
- データベースのパスワード
- セルフホストエンジンを使用している場合には、メンテナンスモードに変更する必要があります。
# hosted-engine --set-maintenance --mode=global
手順9.7 ステップ 1: Manager とは別のマシンへの Data Warehouse のインストールおよび設定
- コンテンツ配信ネットワークにシステムを登録します。プロンプトが表示されたら、カスタマーポータルのユーザー名とパスワードを入力します。
# subscription-manager register
Red Hat Enterprise Linux Server
およびRed Hat Enterprise Virtualization
のサブスクリプションプールを見つけて、プール ID を書き留めておきます。# subscription-manager list --available
- 上記のステップで特定したプール ID を使用して、エンタイトルメントをシステムにアタッチします。
# subscription-manager attach --pool=pool_id
- 既存のリポジトリーをすべて無効にします。
# subscription-manager repos --disable=*
- 必要なチャンネルを有効にします。
# subscription-manager repos --enable=rhel-6-server-rpms # subscription-manager repos --enable=rhel-6-server-supplementary-rpms # subscription-manager repos --enable=rhel-6-server-rhevm-3.6-rpms # subscription-manager repos --enable=jb-eap-6-for-rhel-6-server-rpms
- 現在インストールされている全パッケージを最新の状態にします。
# yum update
- rhevm-dwh-setup パッケージをインストールします。
# yum install rhevm-dwh-setup
engine-setup
コマンドを実行し、そのマシン上で Data Warehouse の設定を開始します。# engine-setup
- Enter を押して Data Warehouse を設定します。
Configure Data Warehouse on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Enter を押して自動検出されたホスト名を受け入れるか、別のホスト名を入力して Enter を押します。
Host fully qualified DNS name of this server [autodetected host name]:
- Data Warehouse データベースに関する以下の質問に回答します。
Where is the DWH database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the DWH to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create DWH database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、リモートデータベースホストに関する情報を提供するように要求されます。 - Manager のデータベースマシンの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。
Engine database host []: engine-db-fqdn Engine database port [5432]: Engine database secured connection (Yes, No) [No]: Engine database name [engine]: Engine database user [engine]: Engine database password: password
- インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
手順9.8 ステップ 2: Manager のマシンへの Reports のインストールおよび設定
- rhevm-reports パッケージをインストールします。
# yum install rhevm-reports
engine-setup
コマンドを実行し、そのマシン上で Reports の設定を開始します。# engine-setup
- Enter を押して Reports を設定します。
Configure Reports on this host (Yes, No) [Yes]:
- Enter を押してファイアウォールを自動設定するか、
No
と入力してから Enter を押して現在の設定を維持します。Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]:
ファイアウォールの自動設定を選択した場合に、ファイアウォール管理機能がアクティブ化されていなければ、サポートされているオプションのリストから選択するファイアウォール管理機能を指定するように要求されるので、そのファイアウォール管理機能の名前を入力して Enter を押してください。この設定は、オプションが 1 つしかリストされていない場合でも適用されます。 - Reports データベースに関する以下の質問に回答します。
Where is the Reports database located? (Local, Remote) [Local]: Setup can configure the local postgresql server automatically for the Reports to run. This may conflict with existing applications. Would you like Setup to automatically configure postgresql and create Reports database, or prefer to perform that manually? (Automatic, Manual) [Automatic]:
Enter を押して提示されているデフォルト値を選択するか、別の回答を入力して Enter を押します。Remote
を選択した場合には、リモートデータベースホストに関する情報を提供するように要求されます。 - Data Warehouse データベースのホストの完全修飾ドメイン名とパスワードを入力します。Enter を押して各フィールドのデフォルト値を受け入れます。
DWH database host []: dwh-db-fqdn DWH database port [5432]: DWH database secured connection (Yes, No) [No]: DWH database name [ovirt_engine_history]: DWH database user [ovirt_engine_history]: DWH database password: password
- Reports の管理ユーザー (
admin
およびsuperuser
) のパスワードを設定します。Reports のシステムは、Manager とは別の独自の認証情報を管理する点に注意してください。Reports power users password:
確認のために、パスワードの再入力を求められます。 - 設定を有効にするには
ovirt-engine
サービスを再起動する必要があります。engine-setup
コマンドは以下のプロンプトを表示します。During execution engine service will be stopped (OK, Cancel) [OK]:
Enter を押して続行します。コマンドの後半にovirt-engine
サービスが再起動します。 - インストールの設定を確認します。
Please confirm installation settings (OK, Cancel) [OK]:
http://demo.redhat.com/ovirt-engine-reports でレポートポータルにアクセスします。demo.redhat.com の箇所は、Manager の完全修飾ドメイン名に置き換えてください。Manager のインストール中にデフォルト以外の HTTP ポートを選択した場合は、URL に :port を追加します。:port を選択したポートに置き換えてください。
admin
というユーザー名と Reports インストール時に設定したパスワードを使用してログインします。Red Hat Enterprise Virtualization Manager Reports への初回ログイン時には、Web ページが複数生成されるため、ログインの完了まで時間がかかる場合があります。
付録A Manager のオペレーティングシステムの手動インストール
手順A.1 Manager のオペレーティングシステムの手動インストール
仮想マシンの設定
hosted-engine
スクリプトにより、Red Hat Enterprise Virtualization Manager として設定される仮想マシンが作成されます。以下の手順では、この仮想マシンを HostedEngine-VM と呼びます。ブートデバイス (該当する場合)、インストールメディアのパス名、CPU タイプ、仮想 CPU の数、ディスクサイズを指定します。HostedEngine-VM の MAC アドレスを指定するか、ランダムに生成された MAC アドレスを適用します。MAC アドレスは、仮想マシンにオペレーティングシステムをインストール前に DHCP サーバーを更新するのに使用することができます。HostedEngine-VM の作成に必要なメモリーサイズとコンソールの接続タイプも指定します。Please specify the device to boot the VM from (cdrom, disk, pxe) [cdrom]: The following CPU types are supported by this host: - model_Penryn: Intel Penryn Family - model_Conroe: Intel Conroe Family Please specify the CPU type to be used by the VM [model_Penryn]: Please specify the number of virtual CPUs for the VM [Defaults to minimum requirement: 2]: Please specify the disk size of the VM in GB [Defaults to minimum requirement: 25]: You may specify a MAC address for the VM or accept a randomly generated default [00:16:3e:77:b2:a4]: Please specify the memory size of the VM in MB [Defaults to minimum requirement: 4096]: Please specify the console type you want to use to connect to the VM (vnc, spice) [vnc]:
ホストエンジンの設定
Red Hat Enterprise Virtualization 環境内で識別するためのセルフホストエンジンの名前と、管理ポータルへアクセスするためのadmin@internal
ユーザーのパスワードを指定します。HostedEngine-VM の FQDN を指定します。この手順では、FQDN に manager.example.com を使用しています。最後に、SMTP サーバーの名前と TCP ポート番号、メール通知に使用するメールアドレス、通知を受信するメールアドレス (複数ある場合はコンマ区切りリスト) を指定します。Enter the name which will be used to identify this host inside the Administrator Portal [hosted_engine_1]: Host-HE1 Enter 'admin@internal' user password that will be used for accessing the Administrator Portal: Confirm 'admin@internal' user password: Please provide the FQDN for the engine you want to use. This needs to match the FQDN that you will use for the engine installation within the VM: manager.example.com Please provide the name of the SMTP server through which we will send notifications [localhost]: Please provide the TCP port number of the SMTP server [25]: Please provide the email address from which notifications will be sent [root@localhost]: Please provide a comma-separated list of email addresses which will get notifications [root@localhost]:
設定のプレビュー
続行する前に、hosted-engine
スクリプトは、入力された設定値を表示して、これらの値で設定を続行するかどうかを尋ねます。Bridge interface : eth1 Engine FQDN : manager.example.com Bridge name : rhevm SSH daemon port : 22 Firewall manager : iptables Gateway address : X.X.X.X Host name for web application : Host-HE1 Host ID : 1 Image size GB : 25 Storage connection : storage.example.com:/hosted_engine/nfs Console type : vnc Memory size MB : 4096 MAC address : 00:16:3e:77:b2:a4 Boot type : pxe Number of CPUs : 2 CPU Type : model_Penryn Please confirm installation settings (Yes, No)[Yes]:
HostedEngine-VM の設定
次にこのスクリプトは、HostedEngine-VM として設定する仮想マシンを作成し、接続情報を表示します。hosted-engine
スクリプトが Host-HE1 上で続行される前に、HostedEngine-VM にオペレーティングシステムをインストールする必要があります。[ INFO ] Stage: Transaction setup ... [ INFO ] Creating VM You can now connect to the VM with the following command: /usr/bin/remote-viewer vnc://localhost:5900 Use temporary password "5379skAb" to connect to vnc console. Please note that in order to use remote-viewer you need to be able to run graphical applications. This means that if you are using ssh you have to supply the -Y flag (enables trusted X11 forwarding). Otherwise you can run the command from a terminal in your preferred desktop environment. If you cannot run graphical applications you can connect to the graphic console from another host or connect to the console using the following command: virsh -c qemu+tls://Test/system console HostedEngine If you need to reboot the VM you will need to start it manually using the command: hosted-engine --vm-start You can then set a temporary password using the command: hosted-engine --add-console-password The VM has been started. Install the OS and shut down or reboot it. To continue please make a selection: (1) Continue setup - VM installation is complete (2) Reboot the VM and restart installation (3) Abort setup (4) Destroy VM and abort setup (1, 2, 3, 4)[1]:
以下のコマンドで VNC プロトコルを使用して仮想マシンに接続します。FQDN は、Host-HE1 の完全修飾ドメイン名または IP アドレスに置き換えます。/usr/bin/remote-viewer vnc://FQDN:5900
仮想マシンのオペレーティングシステムのインストール
hosted-engine
スクリプトで作成した仮想マシン HostedEngine-VM に接続して、Red Hat Enterprise Linux 6.7 のオペレーティングシステムをインストールします。ホストと仮想マシンの同期
Host-HE1 に戻り、オプション 1 を選択してhosted-engine
デプロイメントスクリプトを続行します。(1) Continue setup - VM installation is complete
Manager のインストール
HostedEngine-VM に接続して、適切な Red Hat Enterprise Virtualization Manager リポジトリーにサブスクライブします。『インストールガイド』の「必要なエンタイトルメントのサブスクライブ」を参照してください。インストール済みのパッケージには、すべて最新のバージョンが使用されていることを確認して、rhevm パッケージをインストールします。# yum update
# yum install rhevm
HostedEngine-VM の設定
HostedEngine-VM で engine を設定します。これにより、既存のファイルとデータベースが特定されます。# engine-setup
[ INFO ] Stage: Initializing [ INFO ] Stage: Environment setup Configuration files: ['/etc/ovirt-engine-setup.conf.d/10-packaging.conf', '/etc/ovirt-engine-setup.conf.d/20-setup-ovirt-post.conf'] Log file: /var/log/ovirt-engine/setup/ovirt-engine-setup-20140304075238.log Version: otopi-1.1.2 (otopi-1.1.2-1.el6ev) [ INFO ] Stage: Environment packages setup [ INFO ] Yum Downloading: rhel-65-zstream/primary_db 2.8 M(70%) [ INFO ] Stage: Programs detection [ INFO ] Stage: Environment setup [ INFO ] Stage: Environment customization --== PACKAGES ==-- [ INFO ] Checking for product updates... [ INFO ] No product updates found --== NETWORK CONFIGURATION ==-- Setup can automatically configure the firewall on this system. Note: automatic configuration of the firewall may overwrite current settings. Do you want Setup to configure the firewall? (Yes, No) [Yes]: [ INFO ] iptables will be configured as firewall manager. --== DATABASE CONFIGURATION ==-- --== OVIRT ENGINE CONFIGURATION ==-- Skipping storing options as database already prepared --== PKI CONFIGURATION ==-- PKI is already configured --== APACHE CONFIGURATION ==-- --== SYSTEM CONFIGURATION ==-- --== END OF CONFIGURATION ==-- [ INFO ] Stage: Setup validation [ INFO ] Cleaning stale zombie tasks --== CONFIGURATION PREVIEW ==-- Database name : engine Database secured connection : False Database host : X.X.X.X Database user name : engine Database host name validation : False Database port : 5432 NFS setup : True Firewall manager : iptables Update Firewall : True Configure WebSocket Proxy : True Host FQDN : manager.example.com NFS mount point : /var/lib/exports/iso Set application as default page : True Configure Apache SSL : True Please confirm installation settings (OK, Cancel) [OK]:
設定を確定します。設定が完了すると、SSH フィンガープリントと内部の認証局のハッシュが提示されます。ホストと Manager の同期
Host-HE1 に戻り、オプション 1 を選択してhosted-engine
デプロイメントスクリプトを続行します。(1) Continue setup - engine installation is complete
[ INFO ] Engine replied: DB Up!Welcome to Health Status! [ INFO ] Waiting for the host to become operational in the engine. This may take several minutes... [ INFO ] Still waiting for VDSM host to become operational... [ INFO ] The VDSM Host is now operational Please shutdown the VM allowing the system to launch it as a monitored service. The system will wait until the VM is down.
HostedEngine-VM の終了
HostedEngine-VM を終了します。# shutdown -h now
設定の確認
Host-HE1 に戻り、HostedEngine-VM のリブートが検出されていることを確認します。[ INFO ] Enabling and starting HA services Hosted Engine successfully set up [ INFO ] Stage: Clean up [ INFO ] Stage: Pre-termination [ INFO ] Stage: Termination
付録B Manager 仮想マシン設定の異なるワークフローの比較
付録C 改訂履歴
改訂履歴 | ||||||
---|---|---|---|---|---|---|
改訂 3.6-10.3 | Wed Jul 27 2016 | Red Hat Localization Services | ||||
| ||||||
改訂 3.6-10.2 | Sun Jul 24 2016 | Red Hat Localization Services | ||||
| ||||||
改訂 3.6-10.1 | Sun Mar 13 2016 | Red Hat Localization Services | ||||
| ||||||
改訂 3.6-10 | Wed 09 Mar 2016 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-9 | Tue 01 Mar 2016 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-8 | Mon 22 Feb 2016 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-7 | Fri 19 Feb 2016 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-6 | Wed 27 Jan 2016 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-5 | Wed 23 Dec 2015 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-4 | Tue 08 Dec 2015 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-3 | Wed 18 Nov 2015 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-2 | Wed 18 Nov 2015 | Red Hat Enterprise Virtualization Documentation Team | ||||
| ||||||
改訂 3.6-1 | Mon 31 Aug 2015 | Red Hat Enterprise Virtualization Documentation Team | ||||
|