Configure ElasticSearch in [jaegertracing/all-in-one:latest] docker cotainer.

1,986 views
Skip to first unread message

gustavo...@gmail.com

unread,
Aug 22, 2017, 10:33:25 AM8/22/17
to Jaeger Tracing
Hi,

I'm trying to configure elasticsearch as backend in docker cointainer [jaegertracing/all-in-one:latest], using a docker compose to pass command ["--span-storage.type=elasticsearch"], however when spin up the container, jaeger throws the following error bellow, checking stack trace jaeger needs additional configuration to ES that I unknow.

Thanks for help in advance.

$ sudo docker-compose up jaegertracing
[sudo] senha para arquitetura:
Recreating jaeger_jaegertracing_1
Attaching to jaeger_jaegertracing_1
jaegertracing_1  | {"level":"info","ts":1503411724.191619,"caller":"tchannel/bulider.go:95","msg":"Enabling service discovery","service":"jaeger-collector"}
jaegertracing_1  | {"level":"info","ts":1503411724.19173,"caller":"peerlistmgr/peer_list_mgr.go:117","msg":"Registering active peer","peer":"127.0.0.1:14267"}
jaegertracing_1  | {"level":"info","ts":1503411724.1924257,"caller":"standalone/main.go:117","msg":"Starting agent"}
jaegertracing_1  | {"level":"fatal","ts":1503411724.1925087,"caller":"standalone/main.go:140","msg":"Unable to set up builder","error":"ElasticSearch not configured","stacktrace":"github.com/uber/jaeger/vendor/go.uber.org/zap.Stack\n\t/home/travis/gopath/src/github.com/uber/jaeger/vendor/go.uber.org/zap/field.go:209\ngithub.com/uber/jaeger/vendor/go.uber.org/zap.(*Logger).check\n\t/home/travis/gopath/src/github.com/uber/jaeger/vendor/go.uber.org/zap/logger.go:273\ngithub.com/uber/jaeger/vendor/go.uber.org/zap.(*Logger).Fatal\n\t/home/travis/gopath/src/github.com/uber/jaeger/vendor/go.uber.org/zap/logger.go:208\nmain.startCollector\n\t/home/travis/gopath/src/github.com/uber/jaeger/cmd/standalone/main.go:140\nmain.main.func1\n\t/home/travis/gopath/src/github.com/uber/jaeger/cmd/standalone/main.go:80\ngithub.com/uber/jaeger/vendor/github.com/spf13/cobra.(*Command).execute\n\t/home/travis/gopath/src/github.com/uber/jaeger/vendor/github.com/spf13/cobra/command.go:632\ngithub.com/uber/jaeger/vendor/github.com/spf13/cobra.(*Command).ExecuteC\n\t/home/travis/gopath/src/github.com/uber/jaeger/vendor/github.com/spf13/cobra/command.go:722\ngithub.com/uber/jaeger/vendor/github.com/spf13/cobra.(*Command).Execute\n\t/home/travis/gopath/src/github.com/uber/jaeger/vendor/github.com/spf13/cobra/command.go:681\nmain.main\n\t/home/travis/gopath/src/github.com/uber/jaeger/cmd/standalone/main.go:96"}
jaeger_jaegertracing_1 exited with code 1

-- Docker Compose File:

jaegertracing:
  image: jaegertracing/all-in-one:latest
  ports:
    - "5775:5775/udp"
    - "6831:6831/udp"
    - "6832:6832/udp"
    - "5778:5778"
    - "16686:16686"
    - "14268:14268"
  command:
    - "/go/bin/standalone-linux"
    - "--span-storage.type=elasticsearch"
    - "--query.static-files=/go/src/jaeger-ui-build/build/"



Cheers,

wj...@uber.com

unread,
Aug 22, 2017, 12:03:12 PM8/22/17
to Jaeger Tracing
Hi,

The all-in-one latest container is only meant to be used with the in-memory span store so the elastic search flags aren't exposed. You'd have to run all the components individually with the elastic search flags. You can use https://github.com/uber/jaeger/pull/306/files as an example for a docker-compose file that brings up everything (you can remove the cassandra section). The changes you would have to make are for collector and query which would need to take span-storage.type=elasticsearch

Other more specific elastic search flags are defined here: https://github.com/uber/jaeger/blob/master/cmd/flags/es/options.go#L34 in case you have to change your elastic search host url ie  es.server-urls=http://host:port,http://host:port

gustavo...@gmail.com

unread,
Aug 23, 2017, 7:07:44 AM8/23/17
to Jaeger Tracing
Thank you @wjang

I'm trying to run docker-file without cassandra options, however I'm facing some errors yet. I'm checking out the log errors and taking a look in source code to figure out what happens.

Cheers.
Reply all
Reply to author
Forward
0 new messages