This product is not supported for your selected Datadog site. ().
利用可能な対象:

ログ | メトリクス

概要

Observability Pipelines の Datadog Agent ソースを使用して、Datadog Agent からログまたはメトリクスを受信します。

注:

  • Datadog Distribution of OpenTelemetry (DDOT) Collector を使用してログやメトリクスを収集している場合は、OpenTelemetry ソースを使用してそのデータを Observability Pipelines に送信する必要があります。
  • Datadog Agent は、ddsource および ddtags でタグ付けされたログとメトリクスを送信します。source および tags ではありません。これらのイベントに対してプロセッサークエリやフィルターを定義する場合は、代わりに ddsource および ddtags を使用してください。

前提条件

You already have the Datadog Agent installed to collect and route your logs and/or metrics to Datadog. If you do not have Datadog Agents set up, see the Datadog Agent documentation for more information.

You have the following information available:

セットアップ

シークレット管理の場合: Datadog Agent アドレスの識別子と、該当する場合は TLS キーパスのみを入力します。実際の値は入力しないでください。セットアップ手順については、シークレット管理を参照してください。

パイプラインをセットアップ する際に、このソースをセットアップします。パイプラインのセットアップは、UI で、API を使用して、または Terraform で行えます。このセクションの手順は、UI でソースをセットアップするためのものです。

パイプライン UI で Datadog Agent ソースを選択した後、Datadog Agent アドレスの識別子を入力します。この識別子は、Observability Pipelines Worker が Agent からの接続を待機するバインド先アドレスを参照します(例: <OPW_HOST>:8282)。識別子フィールドを空白のままにすると、デフォルトが使用されます。

If you enter secret identifiers and then choose to use environment variables, the environment variable is the identifier entered and prepended with DD_OP_. For example, if you entered PASSWORD_1 for a password identifier, the environment variable for that password is DD_OP_PASSWORD_1.

オプションの TLS 設定

Toggle the switch to Enable TLS.

  • If you are using Secrets Management, enter the identifier for the key pass. See Secret defaults for the default used if the field is left blank.
  • Enter the following certificate and key files:
    • Server Certificate Path: The path to the certificate file that has been signed by your Certificate Authority (CA) root file in DER, PEM, or CRT (X.509).
    • (Optional) CA Certificate Path: The path to the certificate file that is your Certificate Authority (CA) root file in DER, PEM, or CRT (X.509).
    • (Optional) Private Key Path: The path to the .key private key file that belongs to your Server Certificate Path in DER, PEM, or CRT (PKCS #8) format.
    • Notes:
      • The configuration data directory /var/lib/observability-pipelines-worker/config/ is automatically appended to the file paths. See Advanced Worker Configurations for more information.
      • The file must be readable by the observability-pipelines-worker group and user.

シークレットのデフォルト

These are the defaults used for secret identifiers and environment variables.

  • Datadog Agent アドレス識別子:
    • Observability Pipelines Worker が Datadog Agent からログを受信するためにリッスンするバインド先アドレスを参照します。
    • デフォルトの識別子は SOURCE_DATADOG_AGENT_ADDRESS です。
  • Datadog Agent TLS パスフレーズ識別子 (TLS が有効な場合):
    • デフォルトの識別子は SOURCE_DATADOG_AGENT_KEY_PASS です。
  • Datadog Agent address:
    • The Observability Pipelines Worker listens to this socket address to receive logs from the Datadog Agent.
    • The default environment variable is DD_OP_SOURCE_DATADOG_AGENT_ADDRESS.
  • Datadog Agent TLS passphrase (when enabled):
    • The default environment variable is DD_OP_SOURCE_DATADOG_AGENT_KEY_PASS.

Datadog Agent を Observability Pipelines Worker に接続する

Agent 構成ファイルまたは Agent Helm チャートの値ファイルを使用して、Datadog Agent を Observability Pipelines Worker に接続します。

注: Agent が Docker コンテナで実行されている場合は、DD_CONTAINER_EXCLUDE_LOGS 環境変数を使用して Observability Pipelines のログを除外する必要があります。Helm については、datadog.containerExcludeLogs を使用します。これにより、ワーカーが独自のログを Datadog に直接送信するため、重複ログが防止されます。詳細については、Docker Log の収集または Helm の環境変数を設定するを参照してください。

To send Datadog Agent logs to the Observability Pipelines Worker, update your Agent configuration file with the following:

observability_pipelines_worker:
  logs:
    enabled: true
    url: "http://<OPW_HOST>:8282"

<OPW_HOST> is the host IP address or the load balancer URL associated with the Observability Pipelines Worker.

For CloudFormation installs, use the LoadBalancerDNS CloudFormation output for the URL.

For Kubernetes installs, you can use the internal DNS record of the Observability Pipelines Worker service. For example: http://opw-observability-pipelines-worker.default.svc.cluster.local:<PORT>.

Optionally, to ensure host tags are included in your logs, add the following to your Agent configuration file:

logs_config:
  expected_tags_duration: "1000000m"

expected_tags_duration ensures the Agent attaches host-level tags (such as EC2 instance tags) directly to each log event sent to Observability Pipelines. Without this setting, these tags are applied at the Datadog intake level and are not present in the log payload when it passes through Observability Pipelines. Setting the duration to 1000000m (approximately 1.5 years) covers the standard lifecycle of a node. Note that tags may increase the size of your log.

After you restart the Agent, your observability data should be going to the Worker, processed by the pipeline, and delivered to Datadog.

To send Datadog Agent logs to the Observability Pipelines Worker, update your Datadog Helm chart datadog-values.yaml with the following environment variables. See Agent Environment Variables for more information.

datadog:
  env:
    - name: DD_OBSERVABILITY_PIPELINES_WORKER_LOGS_ENABLED
      value: true
    - name: DD_OBSERVABILITY_PIPELINES_WORKER_LOGS_URL
      value: "http://<OPW_HOST>:8282"

<OPW_HOST> is the IP/URL of the host (or load balancer) associated with the Observability Pipelines Worker.

For Kubernetes installs, you can use the internal DNS record of the Observability Pipelines Worker service. For example: http://opw-observability-pipelines-worker.default.svc.cluster.local:<PORT>.

Optionally, to ensure host tags are included in your logs, add the following to your Agent configuration file:

    - name: DD_LOGS_CONFIG_EXPECTED_TAGS_DURATION
      value: "1000000m"

DD_LOGS_CONFIG_EXPECTED_TAGS_DURATION ensures the Agent attaches host-level tags (such as EC2 instance tags) directly to each log event sent to Observability Pipelines. Without this setting, these tags are applied at the Datadog intake level and are not present in the log payload when it passes through Observability Pipelines. Setting the duration to 1000000m (approximately 1.5 years) covers the standard lifecycle of a node. Note that tags may increase the size of your log.

Agent 構成ファイルまたは Agent Helm チャートの値ファイルを使用して、Datadog Agent を Observability Pipelines Worker に接続します。

注: Agent が Docker コンテナで実行されている場合は、DD_CONTAINER_EXCLUDE_METRICS 環境変数を使用して、利用状況やイン/アウトのイベントのメトリクスなどの Observability Pipelines メトリクスを除外する必要があります。Helm については、datadog.containerExcludeMetrics を使用します。これにより、Worker も独自のメトリクスを Datadog に直接送信するため、重複メトリクスが防止されます。詳細については、Docker メトリクスの収集または Helm の環境変数を設定するを参照してください。

Datadog Agent のメトリクスを Observability Pipelines Worker に送信するには、Agent 構成ファイルを次のように更新します。

observability_pipelines_worker:
  metrics:
    enabled: true
    url: "http://<OPW_HOST>:8383"

<OPW_HOST> は、Observability Pipelines Worker に関連付けられたホスト IP アドレスまたはロードバランサーの URL です。

  • CloudFormation インストールの場合は、URL に LoadBalancerDNS CloudFormation 出力を使用します。
  • Kubernetes インストールの場合は、Observability Pipelines Worker サービスの内部 DNS レコードを使用できます。たとえば: http://opw-observability-pipelines-worker.default.svc.cluster.local:<PORT>。

注: Worker がポート 8282 でログをリッスンしている場合は、メトリクス用に 8383 などの別のポートを使用する必要があります。

Agent を再起動すると、あなたの observability データは、Observability Pipelines Worker に送信され、Observability Pipelines によって処理された後、Datadog に配信されます。

Datadog Agent のメトリクスを Observability Pipelines Worker に送信するには、Datadog Helm チャート datadog-values.yaml を以下の環境変数で更新します。詳細については、Agent の環境変数を参照してください。

datadog:
  env:
    - name: DD_OBSERVABILITY_PIPELINES_WORKER_METRICS_ENABLED
      value: true
    - name: DD_OBSERVABILITY_PIPELINES_WORKER_METRICS_URL
      value: "http://<OPW_HOST>:8383"

<OPW_HOST> は、Observability Pipelines Worker に関連付けられたホスト IP アドレスまたはロードバランサーの URL です。

Kubernetes インストールの場合は、Observability Pipelines Worker サービスの内部 DNS レコードを使用できます。たとえば: http://opw-observability-pipelines-worker.default.svc.cluster.local:<PORT>。

注: Worker がポート 8282 でログをリッスンしている場合は、メトリクス用に 8383 などの別のポートを使用する必要があります。

参考資料