3.9. デバッグデータの収集
サポートケースを作成する際、ご使用のクラスターのデバッグ情報を Red Hat サポートに提供していただくと Red Hat のサポートに役立ちます。
問題のトラブルシューティングに使用するため、以下の情報を提供してください。
-
must-gatherツールを使用して収集されるデータ。 - 一意のクラスター ID。
must-gather ツールを使用して、以下を含む Custom Metrics Autoscaler Operator とそのコンポーネントに関するデータを収集できます。
-
openshift-kedanamespace とその子オブジェクト。 - Custom Metric Autoscaler Operator のインストールオブジェクト。
- Custom Metric Autoscaler Operator の CRD オブジェクト。
3.9.1. デバッグデータの収集 リンクのコピーリンクがクリップボードにコピーされました!
以下のコマンドは、Custom Metrics Autoscaler Operator の must-gather ツールを実行します。
oc adm must-gather --image="$(oc get packagemanifests openshift-custom-metrics-autoscaler-operator \
-n openshift-marketplace \
-o jsonpath='{.status.channels[?(@.name=="stable")].currentCSVDesc.annotations.containerImage}')"
$ oc adm must-gather --image="$(oc get packagemanifests openshift-custom-metrics-autoscaler-operator \
-n openshift-marketplace \
-o jsonpath='{.status.channels[?(@.name=="stable")].currentCSVDesc.annotations.containerImage}')"
標準の OpenShift Container Platform must-gather コマンドである oc adm must-gather は、Custom Metrics Autoscaler Operator データを収集しません。
前提条件
-
cluster-adminロールを持つユーザーとして OpenShift Container Platform にログインしている。 -
OpenShift Container Platform CLI (
oc) がインストールされている。
手順
must-gatherデータを保存するディレクトリーに移動します。注記クラスターがネットワークが制限された環境を使用している場合、追加の手順を実行する必要があります。ミラーレジストリーに信頼される CA がある場合、まず信頼される CA をクラスターに追加する必要があります。制限されたネットワーク上のすべてのクラスターでは、次のコマンドを実行して、デフォルトの
must-gatherイメージをイメージストリームとしてインポートする必要があります。oc import-image is/must-gather -n openshift
$ oc import-image is/must-gather -n openshiftCopy to Clipboard Copied! Toggle word wrap Toggle overflow 以下のいずれかを実行します。
Custom Metrics Autoscaler Operator の
must-gatherデータのみを取得するには、以下のコマンドを使用します。oc adm must-gather --image="$(oc get packagemanifests openshift-custom-metrics-autoscaler-operator \ -n openshift-marketplace \ -o jsonpath='{.status.channels[?(@.name=="stable")].currentCSVDesc.annotations.containerImage}')"$ oc adm must-gather --image="$(oc get packagemanifests openshift-custom-metrics-autoscaler-operator \ -n openshift-marketplace \ -o jsonpath='{.status.channels[?(@.name=="stable")].currentCSVDesc.annotations.containerImage}')"Copy to Clipboard Copied! Toggle word wrap Toggle overflow must-gatherコマンドのカスタムイメージは、Operator パッケージマニフェストから直接プルされます。そうすることで、Custom Metric Autoscaler Operator が利用可能なクラスター上で機能します。Custom Metric Autoscaler Operator 情報に加えてデフォルトの
must-gatherデータを収集するには、以下を実行します。以下のコマンドを使用して Custom Metrics Autoscaler Operator イメージを取得し、これを環境変数として設定します。
IMAGE="$(oc get packagemanifests openshift-custom-metrics-autoscaler-operator \ -n openshift-marketplace \ -o jsonpath='{.status.channels[?(@.name=="stable")].currentCSVDesc.annotations.containerImage}')"$ IMAGE="$(oc get packagemanifests openshift-custom-metrics-autoscaler-operator \ -n openshift-marketplace \ -o jsonpath='{.status.channels[?(@.name=="stable")].currentCSVDesc.annotations.containerImage}')"Copy to Clipboard Copied! Toggle word wrap Toggle overflow Custom Metrics Autoscaler Operator イメージで
oc adm must-gatherを使用するには、以下を実行します。oc adm must-gather --image-stream=openshift/must-gather --image=${IMAGE}$ oc adm must-gather --image-stream=openshift/must-gather --image=${IMAGE}Copy to Clipboard Copied! Toggle word wrap Toggle overflow
例3.1 Custom Metric Autoscaler の must-gather 出力の例
Copy to Clipboard Copied! Toggle word wrap Toggle overflow 作業ディレクトリーに作成された
must-gatherディレクトリーから圧縮ファイルを作成します。たとえば、Linux オペレーティングシステムを使用するコンピューターで以下のコマンドを実行します。tar cvaf must-gather.tar.gz must-gather.local.5421342344627712289/
$ tar cvaf must-gather.tar.gz must-gather.local.5421342344627712289/1 Copy to Clipboard Copied! Toggle word wrap Toggle overflow - 1
must-gather-local.5421342344627712289/を実際のディレクトリー名に置き換えます。
- 圧縮ファイルを Red Hat カスタマーポータル で作成したサポートケースに添付します。