RousselTMLEARNING

Observability

Installing Jaeger v2: all-in-one, configuration and storage

Run Jaeger v2 as all-in-one, understand its configuration file (jaeger_storage and jaeger_query extensions, OTLP pipelines), the ports and the available storage backends.

1. All-in-one #

For learning and testing.

Startup #

docker run --rm --name jaeger \
  -p 16686:16686 -p 4317:4317 -p 4318:4318 \
  jaegertracing/jaeger:latest
# Interface : http://localhost:16686
PortUsage
16686Web interface and query API
4317 / 4318OTLP gRPC / HTTP reception
5778Remote sampling strategies
13133Health check
8888Internal metrics (Prometheus format)
Common mistake: The all-in-one stores traces in memory: everything disappears on restart. Use Badger (local disk) for a persistent test environment, and distributed storage in production.

2. The configuration file #

OpenTelemetry Collector syntax.

Structure #

service:
  extensions: [jaeger_storage, jaeger_query, healthcheckv2]
  pipelines:
    traces:
      receivers: [otlp]
      processors: [batch]
      exporters: [jaeger_storage_exporter]

extensions:
  healthcheckv2:
    use_v2: true
    http:
  jaeger_query:
    storage:
      traces: stockage_principal
  jaeger_storage:
    backends:
      stockage_principal:
        memory:
          max_traces: 100000

receivers:
  otlp:
    protocols:
      grpc: { endpoint: 0.0.0.0:4317 }
      http: { endpoint: 0.0.0.0:4318 }

processors:
  batch:

exporters:
  jaeger_storage_exporter:
    trace_storage: stockage_principal
docker run --rm -v $PWD/config.yaml:/jaeger/config.yaml -p 16686:16686 -p 4317:4317 -p 4318:4318 \
  jaegertracing/jaeger:latest --config /jaeger/config.yaml

Extensions declare the storage backends (jaeger_storage) and the interface (jaeger_query); the pipeline receives OTLP and writes via jaeger_storage_exporter. Any Collector processor (filter, attributes, sampling) can be inserted into the pipeline.

Good to know: Key names change between Jaeger v2 versions: start from the example files in the repository (cmd/jaeger/*.yaml) matching your version.

3. Storage backends #

Choosing by volume.

Options #

StorageUsageNote
memoryDemos, testsLost on restart
badgerSingle instance, persistentLocal disk, no high availability
elasticsearch / opensearchProductionRich search, daily indices, retention by index deletion
cassandraProduction, heavy write volumeRetention by TTL
grpc (remote plugin)Third-party storageFor example ClickHouse via a plugin
extensions:
  jaeger_storage:
    backends:
      es_traces:
        elasticsearch:
          server_urls: [http://elasticsearch:9200]
          indices:
            index_prefix: jaeger
            spans: { date_layout: "2006-01-02", rollover_frequency: day }
Good practice: With Elasticsearch or OpenSearch, retention is managed by deleting old indices: Index Lifecycle Management (ILM) or the jaeger-es-index-cleaner job.

Related articles

Distributed tracing with Jaeger: concepts and architecture

The concepts of distributed tracing (trace, span, context, propagation) and Jaeger: its history, its v2 archi…

Instrumenting applications for Jaeger with OpenTelemetry

Send traces to Jaeger with OpenTelemetry: auto-instrumentation (Java, Python, Node.js), SDK and manual spans,…

Analyzing traces in the Jaeger interface

Search for traces, read a timeline, spot the critical path, compare two traces, use the dependency graph and …

Keep learning

Support us

♥ SUPPORT US

Support RousselTM Learning

Courses, articles, labs and certificates stay free with no intrusive ads. A voluntary contribution, of any amount you choose, pays for hosting, lab environments and new content.

Contribute with PayPal Any amount · card or PayPal accountLearn more
QR code PayPal
Or scan this QR code with your phone

Thank you, every contribution counts!