2.4.5.5. VMware vCenter のホストグループの設定
vSphere ホストグループに対する OpenShift ゾーンのサポートは、テクノロジープレビュー機能です。テクノロジープレビュー機能は、Red Hat 製品のサービスレベルアグリーメント (SLA) の対象外であり、機能的に完全ではないことがあります。Red Hat は、実稼働環境でこれらを使用することを推奨していません。テクノロジープレビュー機能は、最新の製品機能をいち早く提供して、開発段階で機能のテストを行い、フィードバックを提供していただくことを目的としています。
Red Hat のテクノロジープレビュー機能のサポート範囲に関する詳細は、テクノロジープレビュー機能のサポート範囲 を参照してください。
デフォルトのインストール設定ファイルを変更して、ESXi ホストが物理的な場所ごとにホストグループにグループ化されている VMware vSphere ストレッチクラスターに OpenShift Container Platform クラスターをデプロイできます。
OpenShift Container Platform の以前のリリースのデフォルトの install-config.yaml ファイル設定は、非推奨になりました。これは、引き続き使用することはできますが、OpenShift Container Platform インストーラーには、設定ファイルで非推奨のフィールドが使用されていることを示す警告メッセージが表示されます。
前提条件
-
既存の
install-config.yamlインストール設定ファイルがある。 - ESXi ホストをホストグループに配置している。
-
vSphere vCenter クラスターオブジェクトに
Host.Inventory.EditCluster特権を付与している。 -
govcコマンドラインツールをダウンロードしてインストールしている。手順は、VMware ドキュメントの Web サイトを参照してください。govcは、Red Hat のサポートチームによってメンテナンスされていないオープンソースツールであることに注意してください。 TechPreviewNoUpgrade機能セットが有効化されている。詳細は、「フィーチャーゲートを使用した機能の有効化」を参照してください。重要ホストグループのサポートを有効にするには、OpenShift Container Platform クラスターに複数の障害ドメインを定義する必要があります。
手順
次のコマンドを実行して、
openshift-regionおよびopenshift-zonevCenter タグカテゴリーを作成します。重要openshift-regionおよびopenshift-zonevCenter タグカテゴリーに異なる名前を指定すると、OpenShift Container Platform クラスターのインストールは失敗します。$ govc tags.category.create -d "OpenShift region" openshift-region$ govc tags.category.create -d "OpenShift zone" openshift-zone次のコマンドを入力して、OpenShift Container Platform クラスターをデプロイする vSphere クラスターのリージョンタグを作成します。
$ govc tags.create -c <region_tag_category> <region_tag>必要に応じて次のコマンドを入力して、各ホストグループのゾーンタグを作成します。
$ govc tags.create -c <zone_tag_category> <zone_tag>次のコマンドを入力して、リージョンタグを vCenter クラスターオブジェクトにアタッチします。
$ govc tags.attach -c <region_tag_category> <region_tag_1> /<datacenter_1>/host/<cluster_1>ゾーンタグを使用して各 ESXi ホストをホストグループに関連付けるには、各 ESXi ホストに対して次のコマンドを入力します。
$ govc tags.attach -c <zone_tag_category> <zone_tag_for_host_group_1> /<datacenter_1>/host/<cluster_1>/<esxi_host_in_host_group_1>インストールプログラムが含まれるディレクトリーに移動し、選択したインストール要件に従ってクラスターデプロイメントを初期化します。
複数のホストグループを含むサンプル
install-config.yamlファイルfeatureSet: TechPreviewNoUpgrade featureGate: - "VSphereHostVMGroupZonal=true" # ... platform: vsphere: vcenters: # ... datacenters: - <data_center_1_name> failureDomains: - name: <host_group_1> region: <cluster_1_region_tag> zone: <host_group_1_zone_tag> regionType: "ComputeCluster" zoneType: "HostGroup" server: <fully_qualified_domain_name> topology: datacenter: <data_center_1> computeCluster: "/<data_center_1>/host/<cluster_1>" networks: - <VM_Network1_name> hostGroup: <host_group_1_name> datastore: "/<data_center_1>/datastore/<datastore_1>" resourcePool: "/<data_center_1>/host/<cluster_1>/Resources/<resourcePool_1>" folder: "/<data_center_1>/vm/<folder_1>" - name: <host_group_2> region: <cluster_1_region_tag> zone: <host_group_2_zone_tag> regionType: "ComputeCluster" zoneType: "HostGroup" server: <fully_qualified_domain_name> topology: datacenter: <data_center_1> computeCluster: "/<data_center_1>/host/<cluster_1>" networks: - <VM_Network1_name> hostGroup: <host_group_2_name> datastore: "/<data_center_1>/datastore/<datastore_1>" resourcePool: "/<data_center_1>/host/<cluster_1>/Resources/<resourcePool_1>" folder: "/<data_center_1>/vm/<folder_1>"