はじめに
- みなさん!メリークリスマス!Advent Calendar8日目は、OpenShiftにおけるInstanaのconfiguration設定(Operator Hub編)の記事となります。
- ホストにInstana Agentをインストール後、Instana Agent用の設定ファイル (configuration.yaml など) を編集することで、Instana UI上の表示変更や、アプリケーション開発フレームワーク、データベースの詳細を可視化などといった、様々な設定を適用できます。
- OpenShiftには、複数のInstana Agentインストール方法があります、今回は、Operator Hubによる設定および編集方法を紹介します。
- また、手動設定によるOperator編やHelm Chart編も公開予定なのでお楽しみに!
公式ドキュメントのリンク
- 実際に設定するときは必ず公式ドキュメントをチェックしてください!
- https://www.ibm.com/docs/ja/instana-observability/latest?topic=agents-installing-red-hat-openshift
設定の前提条件
-
OpenShift 4.18に対して、Operator HubによるInstana Agentインストールおよび編集をします。 -
Instana UIのインフラストラクチャーマップにおいて、「Instana Maturity Zone」というカスタムゾーンを設定します。
-
下記は、今回変更する
configurationの抜粋となります。com.instana.plugin.generic.hardware: enabled: true availability-zone: 'Instana Maturity Zone'
Operator Hubによる設定例
Operator Hubによるconfiguration設定例
- OpenShiftのダッシュボードより、OperatorHubを選択し、Instana Agentをインストールします。
- インストール済みのOperatorより、Instana Agentを作成します。
-
ここで、YAMLビューより
configuration_yamlを設定します。kind: InstanaAgent apiVersion: instana.io/v1 metadata: name: instana-agent namespace: instana-agent spec: agent: configuration_yaml: | com.instana.plugin.generic.hardware: enabled: true availability-zone: 'Instana Maturity Zone' endpointHost: <endpointHost Name> endpointPort: '443' env: {} key: <key> cluster: name: my-cluster opentelemetry: grpc: enabled: true http: enabled: true zone: name: #オプション
zone.name: my-zoneを指定すると、configuration_yamlのavailability-zoneが反映されません。(他のconfigを追加すると、その設定は反映されます)。 zone.name:(空白)とすると、configuration_yamlのavailability-zoneが反映されます。
- Instana Agentが問題なく動作していることを確認します。
- Instanaのインフラストラクチャーマップで、Zone名が
Instana Maturity Zoneになっていることを確認します。
Operator Hubによるconfiguration設定変更例
- インストール済みのOperatorより、
availability-zoneを'Instana Maturity Zone Operator'に変更をし、最後に保存を押します。
- Instanaのインフラストラクチャーマップで、Zone名が変更されていることを確認できます。
おわりに
- Operator HubによるInstana Agentインストールや設定変更は、OpenShiftのダッシュボードから直感的に行うことができますね!
- 一方で、手順書として残すことを考えた場合、GUIの変更のたびに手順書のアップデートが必要となり、継続的なメンテナンスに時間を要する可能性もあります。
- 別の記事では、手動設定によるOperatorやHelm Chartによる方法を公開予定ですので、ぜひご覧ください!良い年末を!








