Docs » Splunk Distribution of the OpenTelemetry Collector の利用開始 » Collector for Kubernetesを使い始める » Install the Collector for Kubernetes using Helm

Install the Collector for Kubernetes using Helm 🔗

You can install the Splunk Distribution of the OpenTelemetry Collector for Kubernetes using a Helm chart to define, install, and upgrade Kubernetes applications.

ヘルムチャートを使って次のことを行います:

  • Kubernetesクラスターの他のKubernetesオブジェクトと一緒にKubernetes DaemonSetを作成します。

  • Splunk Enterprise、Splunk Cloud Platform、Splunk Observability Cloud のメトリクス、トレース、ログデータの受信、処理、エクスポート。

To learn more about the Collector for Kubernetes Helm chart, see:

対応Kubernetesディストリビューション 🔗

Helmチャートは主要なKubernetesディストリビューションのデフォルト設定で動作します。アクティブにサポートされているバージョンを使用してください:

このチャートは他の Kubernetes ディストリビューションでも動作するはずですが、デフォルトの values.yaml 設定ファイルは、追加の更新が必要になる可能性があります。

前提条件 🔗

チャートを使用するには、以下のリソースが必要です:

  • Helm 3 。Helm 2はサポートされていません。

  • Kubernetesクラスターへの管理者アクセス。

前提条件:デスティネーション 🔗

Collector for Kubernetes には、デスティネーションが必要です:Splunk Enterprise または Splunk Cloud Platform ( splunkPlatform ) または Splunk Observability Cloud ( splunkObservability ) です。

宛先によっては次が必要です:

  • splunkPlatform にデータを送信するには:

    • Splunk Enterprise 8.0 以上。

    • ログデータを収集するための、最低 1つの Splunk プラットフォームインデックス。このインデックスはログの取り込みに使用されます。

    • HTTP Event Collector (HEC) トークンとエンドポイント。Set up and use HTTP Event Collector in Splunk Web および Scale HTTP Event Collector を参照してください。

    • splunkPlatform.endpoint.Splunk インスタンスへの URL、例: "http://localhost:8088/services/collector"

    • splunkPlatform.token.Splunk HTTP Event Collector トークン。

  • splunkObservability にデータを送信するには:

注釈

Collector for Kubernetes が使用するデフォルトの Splunk プラットフォームインデックスは main です。

ヘルムチャートのデプロイ 🔗

以下のコマンドを実行して、Helmチャートをデプロイします:

  1. Helmレポを追加します:

    helm repo add splunk-otel-collector-chart https://signalfx.github.io/splunk-otel-collector-chart
    
  2. デスティネーションを決めます。

    Splunk Observability Cloudの場合:

    helm install my-splunk-otel-collector --set="splunkObservability.realm=us0,splunkObservability.accessToken=xxxxxx,clusterName=my-cluster" splunk-otel-collector-chart/splunk-otel-collector
    

    Splunk Enterprise または Splunk Cloud Platform の場合:

    helm install my-splunk-otel-collector --set="splunkPlatform.endpoint=https://127.0.0.1:8088/services/collector,splunkPlatform.token=xxxxxx,splunkPlatform.metricsIndex=k8s-metrics,splunkPlatform.index=main,clusterName=my-cluster" splunk-otel-collector-chart/splunk-otel-collector
    

    Splunk Observability Cloud と Splunk Enterprise または Splunk Cloud Platform の両方が対象です:

    helm install my-splunk-otel-collector --set="splunkPlatform.endpoint=https://127.0.0.1:8088/services/collector,splunkPlatform.token=xxxxxx,splunkPlatform.metricsIndex=k8s-metrics,splunkPlatform.index=main,splunkObservability.realm=us0,splunkObservability.accessToken=xxxxxx,clusterName=my-cluster" splunk-otel-collector-chart/splunk-otel-collector
    
  3. チャートをデプロイする名前空間を -n 引数で指定します:

    helm -n otel install my-splunk-otel-collector -f values.yaml splunk-otel-collector-chart/splunk-otel-collector
    

注意

values.yaml ファイルには、Helm チャートでサポートされているすべての設定可能なパラメータと、各パラメータの詳細な説明が記載されています。:strong:` このチャートの設定方法を理解するために、このファイルを見てください`。

また、トレースサンプリングやプロキシサーバー経由のデータ送信など、さまざまなユースケースをサポートするようにHelmチャートを設定することもできます。詳しくは チャート設定の例 を参照してください。

その他のパラメータの設定 🔗

以下の設定が可能です:

例:

helm repo add splunk-otel-collector-chart https://signalfx.github.io/splunk-otel-collector-chart
helm install my-splunk-otel-collector --set="splunkRealm=us0,splunkAccessToken=xxxxxx,clusterName=my-cluster" --set=distribution={value},cloudProvider={value} splunk-otel-collector-chart/splunk-otel-collector

YAMLファイルを使ってHelmを設定する 🔗

YAMLファイルを使ってHelmの値を引数に設定することもできます。たとえば、my_values.yaml という名前の YAML ファイルを作成したら、次のコマンドを実行して Helm チャートをデプロイします:

helm install my-splunk-otel-collector --values my_values.yaml splunk-otel-collector-chart/splunk-otel-collector

See an example of a YAML file in GitHub .

Prometheus・メトリクスの設定 🔗

Helmチャートの値のYAMLにこのプロパティを追加することで、Prometheusを発するポッドを自動的にスクレイピングするようにCollectorを設定します:

autodetect:
   prometheus: true

デプロイメント内のすべてのポッドのリソースファイルにこの設定を追加します:

metadata:
   annotations:
      prometheus.io/scrape: "true"
      prometheus.io/path: /metrics
      prometheus.io/port: "8080"

デプロイを確認する 🔗

チャートが正常にデプロイされると、Splunk Distribution of OpenTelemetry Collector for Kubernetes が Kubernetes クラスターにデプロイされていることを知らせるメッセージ、最終デプロイ日、ステータスが出力されます。

OpenTelemetryでKubernetes Operatorを使用する 🔗

Using the Splunk Helm chart, you can install the Splunk Collector along with an upstream OpenTelemetry Kubernetes Operator for Auto Instrumentation. For more information, see Automatic discovery and configuration for Kubernetes.

This instance of the Kubernetes Operator is part of the upstream OpenTelemetry Operator project. See the OpenTelemetry GitHub repo <OpenTelemetry GitHub repo for more information.

注釈

アップストリームの Kubernetes Operator は、Kubernetes インフラストラクチャに Splunk Enterprise デプロイメントをデプロイして運用するために使用する Splunk Operator for Kubernetes とは関係ありません。

Splunk Distribution for the Kubernetes Operator (アルファ版) 🔗

注意

このプロジェクトはアルファ版です。本番では使用しないでください。

The Splunk Distribution of OpenTelemetry Collector for Kubernetes Operator is the Splunk Observability Cloud implementation of a Kubernetes Operator, and it helps deploy and manage the Splunk Distribution of the OpenTelemetry Collector for Kubernetes. See the README file in GitHub for installation instructions.

次のステップ 🔗

After installing the package you can:

This page was last updated on 2024年05月29日.