oVirt 4.4 : oVirt 管理ノードの設定2020/07/13 |
|
Red Hat Virtualization (RHV) の オープンソース実装 oVirt のインストールと設定です。
当例では以下のような環境を例に設定します。
+-----------------------+ | +-----------------------+
| [ Admin Node ] |10.0.0.30 | 10.0.0.25| [ oVirt Engine ] |
| dlp.srv.world +----------+----------+ ctrl.srv.world |
| | | | |
+-----------------------+ | +-----------------------+
|
+-----------------------+ |
| [ Shared Storage ] |10.0.0.35 |
| nfs.srv.world +----------+
| |
+-----------------------+
|
|
[oVirt Engine] は 設定ツールにより、管理ノード上に仮想マシンで構築されます。
よって、事前に [oVirt Engine] 用に、名前解決可能な IP アドレスを用意しておく必要があります。
また oVirt ノード間で共有ストレージが必要になります。
NFS, ISCSI, FCP, GlusterFS が使用可能となっています。 当例では上記のように NFS サーバーを使用します。 |
|
| [1] |
こちらを参考に SMTP サーバーをインストールして起動しておきます。
各種メール通知に使用されます。当例では管理ノードにインストールして進めます。 |
| [2] |
こちらを参考に NFS サーバーをインストールして起動しておきます。
なお、当例では [nfs.srv.world] 上の [/var/lib/ovirt-share] を共有ディレクトリとして設定します。 |
| [3] | NFS サーバー上に必要な ユーザー/グループ を作成しておきます。 |
|
[root@nfs ~]# groupadd kvm -g 36 [root@nfs ~]# useradd vdsm -u 36 -g 36 -s /sbin/nologin -M -d / [root@nfs ~]# chown -R vdsm:kvm /var/lib/ovirt-share [root@nfs ~]# chmod 755 /var/lib/ovirt-share |
| [4] | 管理ノード上で [oVirt Engine] を構成します。 |
|
[root@dlp ~]#
dnf -y install https://resources.ovirt.org/pub/yum-repo/ovirt-release44.rpm
[root@dlp ~]#
[root@dlp ~]# dnf -y install ovirt-hosted-engine-setup hosted-engine --deploy
[ INFO ] Stage: Initializing
[ INFO ] Stage: Environment setup
During customization use CTRL-D to abort.
Continuing will configure this host for serving as hypervisor and will create a local VM with a running engine.
The locally running engine will be used to configure a new storage domain and create a VM there.
At the end the disk of the local VM will be moved to the shared storage.
# そのまま Enter
Are you sure you want to continue? (Yes, No)[Yes]:
Configuration files:
Log file: /var/log/ovirt-hosted-engine-setup/ovirt-hosted-engine-setup-20200710104518-uepm1p.log
Version: otopi-1.9.2 (otopi-1.9.2-1.el8)
.....
.....
[ INFO ] Stage: Environment customization
--== STORAGE CONFIGURATION ==--
--== HOST NETWORK CONFIGURATION ==--
# ゲートウェイの IP アドレスを指定
Please indicate the gateway IP address [10.0.0.1]:
.....
.....
# ブリッジを構成するネットワークインターフェースを指定
Please indicate a nic to set ovirtmgmt bridge on: (enp1s0) [enp1s0]:
Please specify which way the network connectivity should be checked (ping, dns, tcp, none) [dns]:
--== VM CONFIGURATION ==--
# [datacenter] の名称を設定 (任意の名称)
Please enter the name of the datacenter where you want to deploy this hosted-engine host. [Default]:
# [cluster] の名称を設定 (任意の名称)
Please enter the name of the cluster where you want to deploy this hosted-engine host. [Default]:
If you want to deploy with a custom engine appliance image,
please specify the path to the OVA archive you would like to use
# [OVA archive] を使用する場合は Path を指定
# 空 Enter でスキップ (後から設定可能)
(leave it empty to skip, the setup will use ovirt-engine-appliance rpm installing it if missing):
# oVirt Engine 仮想マシンの仮想 CPU 数を設定
Please specify the number of virtual CPUs for the VM (Defaults to appliance OVF value): [4]:
# oVirt Engine 仮想マシンのメモリサイズを設定 (MB)
Please specify the memory size of the VM in MB (Defaults to maximum available): [14776]:
[ INFO ] Detecting host timezone.
Please provide the FQDN you would like to use for the engine.
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.
# oVirt Engine 仮想マシンの FQDN を指定
Engine VM FQDN: []: ctrl.srv.world
Please provide the domain name you would like to use for the engine appliance.
# ドメインを指定
Engine VM domain: [srv.world]
# oVirt Engine 仮想マシンの root パスワードを設定
Enter root password that will be used for the engine appliance:
Confirm appliance root password:
# oVirt Engine 仮想マシンに SSH 鍵鍵を設定する場合は公開鍵を指定
Enter ssh public key for the root user that will be used for the engine appliance (leave it empty to skip):
[WARNING] Skipping appliance root ssh public key
# oVirt Engine 仮想マシンへの SSH での root ログイン許可/不許可の設定
Do you want to enable ssh access for the root user (yes, no, without-password) [yes]:
# OpenSCAP の デフォルト セキュリティプロファイル を適用するか否か
Do you want to apply a default OpenSCAP security profile (Yes, No) [No]:
# 仮想マシンに設定する MAC アドレス
You may specify a unicast MAC address for the VM or accept a randomly generated default [00:16:3e:1c:e9:23]:
# oVirt Engine 仮想マシンのネットワーク設定 (DHCP or 固定)
How should the engine VM network be configured (DHCP, Static)[DHCP]? Static
# 固定 IP を選択した場合は IP アドレスを設定
Please enter the IP address to be used for the engine VM []: 10.0.0.25
[ INFO ] The engine VM will be configured to use 10.0.0.25/24
Please provide a comma-separated list (max 3) of IP addresses of domain name servers for the engine VM
# 仮想マシンが参照する DNS を設定
Engine VM DNS (leave it empty to skip) [10.0.0.10]:
# 仮想マシンのローカル [/etc/hosts] に上記ホストを追加するか否か
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]
--== HOSTED ENGINE CONFIGURATION ==--
# 通知メール送信に使用する SMTP サーバー
Please provide the name of the SMTP server through which we will send notifications [localhost]:
# SMTP サーバーが使用するポート
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]:
# oVirt Engine の admin パスワードを設定
Enter engine admin password:
Confirm engine admin password:
[ INFO ] Stage: Setup validation
# 管理ノードのホスト名を指定
Please provide the hostname of this host on the management network [dlp.srv.world]:
.....
.....
# 使用する共有ストレージを指定
Please specify the storage you would like to use (glusterfs, iscsi, fc, nfs)[nfs]:
# NFS を選択した場合はバージョンを指定
Please specify the nfs version you would like to use (auto, v3, v4, v4_0, v4_1, v4_2)[auto]:
# 共有のパスを指定
Please specify the full shared storage connection path to use (example: host:/path): nfs.srv.world:/var/lib/ovirt-share
# 必要に応じてマウントオプション指定可
If needed, specify additional mount options for the connection to the hosted-engine storagedomain (example: rsize=32768,wsize=32768) []:
.....
.....
# oVirt Engine 仮想マシンに割り当てるディスク容量を指定
Please specify the size of the VM disk in GiB: [51]:
.....
.....
[ INFO ] Generating answer file '/var/lib/ovirt-hosted-engine-setup/answers/answers-20200710114842.conf'
[ INFO ] Generating answer file '/etc/ovirt-hosted-engine/answers.conf'
[ INFO ] Stage: Pre-termination
[ INFO ] Stage: Termination
[ INFO ] Hosted Engine successfully deployed
# 仮想マシン [HostedEngine] が稼働 [root@dlp ~]# virsh -c qemu:///system?authfile=/etc/ovirt-hosted-engine/virsh_auth.conf list Id Name State ------------------------------ 3 HostedEngine running # oVirt Engine 仮想マシンのステータス確認 [root@dlp ~]# hosted-engine --vm-status
--== Host dlp.srv.world (id: 1) status ==--
Host ID : 1
Host timestamp : 12291
Score : 3400
Engine status : {"vm": "up", "health": "good", "detail": "Up"}
Hostname : dlp.srv.world
Local maintenance : False
stopped : False
crc32 : 26a47de0
conf_on_shared_storage : True
local_conf_timestamp : 12291
Status up-to-date : True
Extra metadata (valid at timestamp):
metadata_parse_version=1
metadata_feature_version=1
timestamp=12291 (Fri Jul 10 12:50:29 2020)
host-id=1
score=3400
vm_conf_refresh_time=12291 (Fri Jul 10 12:50:30 2020)
conf_on_shared_storage=True
maintenance=False
state=EngineUp
stopped=False
# oVirt Engine 仮想マシンにコンソール接続する # 戻る場合は通常の libvirt の操作と同じ [root@dlp ~]# hosted-engine --console The engine VM is running on this host Escape character is ^] CentOS Linux 8 (Core) Kernel 4.18.0-193.6.3.el8_2.x86_64 on an x86_64 Web console: https://ctrl.srv.world:9090/ or https://10.0.0.25:9090/ ctrl login: |
| Sponsored Link |
|
|