OpenTelemetry Collector: Debugging, Operations, and Scaling
Internal Logs of the Collector
How to view and configure OpenTelemetry Collector internal logs, control log levels and formats, stream logs in environments, and troubleshoot startup and runtime issues
In this lesson we cover how to read and configure the OpenTelemetry Collector’s internal logs to help diagnose startup, pipeline loading, configuration issues, and runtime problems.By default the Collector writes internal logs to standard error (stderr) at the INFO level even if you do not configure service.telemetry.logs. These logs include startup/shutdown messages, pipeline readiness confirmations, component warnings, and metadata such as the Collector version and service instance ID.
By default the Collector logs internal activity at INFO to standard error (stderr). This provides immediate visibility into startup and runtime behavior without adding any telemetry configuration.
To control Collector internal logging (verbosity, format, sampling, and destinations), add a service.telemetry.logs block under service. The level field accepts DEBUG, INFO, WARN, and ERROR.
DEBUG: detailed component-level activity — useful for development and troubleshooting.
INFO: default operational messages.
WARN / ERROR: reduce output to only problematic events — recommended for production.
Example: enable debug-level logs to get more detailed initialization output:
PS C:\ProgramData\OpenTelemetry Collector> otelcol-contrib --config .\nop-w-telemetry.yaml2025-11-09T19:04:35.396+1100 info service@v0.132.0:187 Setting up own telemetry... {"resource": {"service.instance.id": "21fa506d-662f-467f-9e0c-77de328804d6", "service.name": "otelcol-contrib", "service.version": "0.132.0"}}2025-11-09T19:04:35.397+1100 debug builders/builders.go:24 Beta component. May change in the future. {"resource": {"service.instance.id": "21fa506d-662f-467f-9e0c-77de328804d6", "service.name": "otelcol-contrib", "service.version": "0.132.0", "otelcol.component.id": "nop", "otelcol.component.kind": "exporter", "otelcol.signal": "traces"}}2025-11-09T19:04:35.397+1100 debug builders/builders.go:24 Beta component. May change in the future. {"resource": {"service.instance.id": "21fa506d-662f-467f-9e0c-77de328804d6", "service.name": "otelcol-contrib", "service.version": "0.132.0", "otelcol.component.id": "nop", "otelcol.component.kind": "receiver", "otelcol.signal": "traces"}}2025-11-09T19:04:35.397+1100 info service@v0.132.0/service.go:249 Starting otelcol-contrib... {"resource": {"service.instance.id": "21fa506d-662f-467f-9e0c-77de328804d6", "service.name": "otelcol-contrib", "service.version": "0.132.0"}, "Version": "0.132.0"}2025-11-09T19:04:35.397+1100 info extensions/extensions.go:41 Starting extensions... {"resource": {"service.instance.id": "21fa506d-662f-467f-9e0c-77de328804d6", "service.name": "otelcol-contrib", "service.version": "0.132.0"}}2025-11-09T19:04:35.397+1100 info service@v0.132.0/service.go:272 Everything is ready. {"resource": {"service.instance.id": "21fa506d-662f-467f-9e0c-77de328804d6", "service.name": "otelcol-contrib", "service.version": "0.132.0"}}
YAML to set the level to DEBUG:
service: telemetry: logs: level: "DEBUG"
For production use a higher threshold such as ERROR:
Writing logs to local files or enabling DEBUG in production can increase disk usage and expose sensitive details. Review retention and access controls if you persist Collector logs.
When encoding: json is enabled, each log line is a JSON object which is much easier to ingest and query in centralized log systems. During debugging, keep disable_stacktrace: false and disable_caller: false to get file/line and stack traces for errors.Example pipeline + telemetry configuration — ensure the telemetry block is nested under service:
service.telemetry.logs.level controls the Collector’s internal log verbosity (this is separate from telemetry data you collect or export).
By default, the Collector emits INFO-level logs to stderr.
Use journalctl, docker logs, or kubectl logs to access Collector logs in common environments.
Tune level, encoding, sampling, and output_paths to balance visibility and performance.
Persist or forward internal logs to a centralized backend to aid cross-system troubleshooting and historical analysis.
This is the first place to inspect when validating pipeline initialization or diagnosing why telemetry data is not reaching its backend. For more details, see the Collector documentation and the OpenTelemetry specifications: