No logs on grafana cloud using opentelemetry collector

Hi,

I’m facing an issue when trying to send logs from my kubernetes cluster to Grafana cloud loki.

I’m using the opentelemetry-collector chart version 0.92.0.

Below the content of my value file:

image:
  repository: otel/opentelemetry-collector-contrib
mode: daemonset
config:
  extensions:
    health_check: {}
    basicauth/otlp:
      client_auth:
        username: xxxxxxxxx
        password: xxxxxxxxx
  receivers:
    filelog:
      include:
        - /var/log/pods/*/*/*.log
  exporters:
    otlphttp:
      auth:
        authenticator: basicauth/otlp
      endpoint: https://otlp-gateway-prod-eu-west-2.grafana.net/otlp
  service:
    extensions: 
      - health_check
      - basicauth/otlp
    pipelines:
      logs:
        receivers: [filelog]
        processors:  [batch]
        exporters: [otlphttp]

No error log displayed and I don’t receive anything on Grafana Cloud side.

N.B: I have another opentelemetry-collector deployment that collect metrics and it works like a charm.

I’ve followed this non exhaustive configuration template to generate the values.

I’ve tried this but the documentation is deprecated (tenand_id and labels not recognized attribute).

Am I missing something?

Thanks for your help.

Seb.

Use debug exporter and validate that collector has some logs first.

I would say you don’t have volume with logs from host, so there are not logs available on the pod level.

Follow better doc, pls: Important Components for Kubernetes | OpenTelemetry

Pls post formated codes.