3.4. ネットワーク検証を手動で実行する
Red Hat OpenShift Service on AWS (ROSA) クラスターをインストールした後、Red Hat OpenShift Cluster Manager または ROSA CLI (rosa
) を使用してネットワーク検証チェックを手動で実行できます。
OpenShift Cluster Manager を使用してネットワーク検証を手動で実行する
Red Hat OpenShift Cluster Manager を使用して、既存の Red Hat OpenShift Service on AWS (ROSA) クラスターのネットワーク検証チェックを手動で実行できます。
前提条件
- 既存の ROSA クラスターがあります。
- クラスター所有者になっているか、クラスター編集者のロールがある。
手順
- OpenShift Cluster Manager に移動し、クラスターを選択します。
- Actions ドロップダウンメニューから Verify networking を選択します。
CLI を使用してネットワーク検証を手動で実行する
ROSA CLI (rosa
) を使用して、既存の Red Hat OpenShift Service on AWS (ROSA) クラスターのネットワーク検証チェックを手動で実行できます。
ネットワーク検証を実行するときは、一連の VPC サブネット ID またはクラスター名を指定できます。
前提条件
-
インストールホストに、最新の ROSA CLI (
rosa
) をインストールして設定している。 - 既存の ROSA クラスターがあります。
- クラスター所有者になっているか、クラスター編集者のロールがある。
手順
次のいずれかの方法を使用して、ネットワーク設定を確認します。
クラスター名を指定してネットワーク設定を確認します。サブネット ID は自動的に検出されます。
$ rosa verify network --cluster <cluster_name> 1
- 1
<cluster_name>
は、クラスター名に置き換えます。
出力例
I: Verifying the following subnet IDs are configured correctly: [subnet-03146b9b52b6024cb subnet-03146b9b52b2034cc] I: subnet-03146b9b52b6024cb: pending I: subnet-03146b9b52b2034cc: passed I: Run the following command to wait for verification to all subnets to complete: rosa verify network --watch --status-only --region us-east-1 --subnet-ids subnet-03146b9b52b6024cb,subnet-03146b9b52b2034cc
すべてのサブネットに対する検証が完了していることを確認します。
$ rosa verify network --watch \ 1 --status-only \ 2 --region <region_name> \ 3 --subnet-ids subnet-03146b9b52b6024cb,subnet-03146b9b52b2034cc 4
- 1
watch
フラグを使用すると、テスト対象のすべてのサブネットが失敗または合格状態になった後でコマンドが完了します。- 2
status-only
フラグは、ネットワーク検証の実行をトリガーしませんが、現在の状態 (例:subnet-123 (検証はまだ進行中))
を返します。デフォルトでは、このオプションを使用しない場合、このコマンドを呼び出すと、指定されたサブネットの検証が常にトリガーされます。- 3
- AWS_REGION 環境変数をオーバーライドする特定の AWS リージョンを使用します。
- 4
- コンマで区切られたサブネット ID のリストを入力して確認します。いずれかのサブネットが存在しない場合は、
Network verification for subnet 'subnet-<subnet_number> not found
というエラーメッセージが表示され、サブネットはチェックされません。
出力例
I: Checking the status of the following subnet IDs: [subnet-03146b9b52b6024cb subnet-03146b9b52b2034cc] I: subnet-03146b9b52b6024cb: passed I: subnet-03146b9b52b2034cc: passed
ヒント検証テストの完全なリストを出力するには、
rosa verify network
コマンドを実行するときに--debug
引数を含めることができます。
VPC サブネット ID を指定してネットワーク設定を確認します。
<region_name>
は AWS リージョンに置き換え、<AWS_account_ID>
は AWS アカウント ID に置き換えます。$ rosa verify network --subnet-ids 03146b9b52b6024cb,subnet-03146b9b52b2034cc --region <region_name> --role-arn arn:aws:iam::<AWS_account_ID>:role/my-Installer-Role
出力例
I: Verifying the following subnet IDs are configured correctly: [subnet-03146b9b52b6024cb subnet-03146b9b52b2034cc] I: subnet-03146b9b52b6024cb: pending I: subnet-03146b9b52b2034cc: passed I: Run the following command to wait for verification to all subnets to complete: rosa verify network --watch --status-only --region us-east-1 --subnet-ids subnet-03146b9b52b6024cb,subnet-03146b9b52b2034cc
すべてのサブネットに対する検証が完了していることを確認します。
$ rosa verify network --watch --status-only --region us-east-1 --subnet-ids subnet-03146b9b52b6024cb,subnet-03146b9b52b2034cc
出力例
I: Checking the status of the following subnet IDs: [subnet-03146b9b52b6024cb subnet-03146b9b52b2034cc] I: subnet-03146b9b52b6024cb: passed I: subnet-03146b9b52b2034cc: passed