9.2. must-gather ツールの使用
must-gather
ツールを使用して、MTV カスタムリソース (CR) のログおよび情報を収集できます。must-gather
データファイルをすべてのカスタマーケースに割り当てる必要があります。
フィルタリングオプションを使用して、特定の namespace、移行計画、または仮想マシンのデータを収集できます。
フィルターされた must-gather
コマンドで存在しないリソースを指定すると、アーカイブファイルは作成されません。
前提条件
-
cluster-admin
ロールを持つユーザーとして OpenShift Virtualization クラスターにログインしている。 -
Red Hat OpenShift CLI (
oc
) がインストールされている。
ログおよび CR 情報の収集
-
must-gather
データを保存するディレクトリーに移動します。 oc adm must-gather
コマンドを実行します。Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7
$ oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7
データは
/must-gather/must-gather.tar.gz
として保存されます。このファイルを Red Hat カスタマーポータル で作成したサポートケースにアップロードできます。オプション:
oc adm must-gather
コマンドに以下のオプションを指定して実行し、フィルターされたデータを収集します。Namespace:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7 \ -- NS=<namespace> /usr/bin/targeted
$ oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7 \ -- NS=<namespace> /usr/bin/targeted
移行計画:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7 \ -- PLAN=<migration_plan> /usr/bin/targeted
$ oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7 \ -- PLAN=<migration_plan> /usr/bin/targeted
仮想マシン:
Copy to Clipboard Copied! Toggle word wrap Toggle overflow oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7 \ -- VM=<vm_id> NS=<namespace> /usr/bin/targeted
$ oc adm must-gather --image=registry.redhat.io/migration-toolkit-virtualization/mtv-must-gather-rhel8:2.5.7 \ -- VM=<vm_id> NS=<namespace> /usr/bin/targeted
1 - 1
Plan
CR に表示される仮想マシンの ID を指定します。