# Elasticsearch, Logstash and Kibana with Docker Compose

**URL:** <https://discuss.elastic.co/t/elasticsearch-logstash-and-kibana-with-docker-compose/81689>\
**Category:** Kibana\
**Created:** [April 8, 2017, 8:59pm UTC](https://discuss.elastic.co/t/elasticsearch-logstash-and-kibana-with-docker-compose/81689 "2017-04-08T20:59:00Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![John\_06](https://avatars.discourse-cdn.com/v4/letter/j/7c8e57/32.png) [@John\_06](https://discuss.elastic.co/u/John_06)\
**Post date:** [April 8, 2017, 8:59pm UTC](https://discuss.elastic.co/t/elasticsearch-logstash-and-kibana-with-docker-compose/81689/1 "2017-04-08T20:59:00Z")

</div>

## I am trying to start all 3 apps with docker-compose command using the following `docker-compose.yml` file:

version: '2'  
services:  
kibana:  
image: [docker.elastic.co/kibana/kibana:5.3.0](http://docker.elastic.co/kibana/kibana:5.3.0)  
links:  
- elasticsearch  
ports:  
- 5601:5601

logstash:  
image: [docker.elastic.co/logstash/logstash:5.3.0](http://docker.elastic.co/logstash/logstash:5.3.0)  
links:  
- elasticsearch  
ports:  
- 5044:5044

elasticsearch:  
image: [docker.elastic.co/elasticsearch/elasticsearch:5.3.0](http://docker.elastic.co/elasticsearch/elasticsearch:5.3.0)  
cap\_add:  
- IPC\_LOCK  
volumes:  
- esdata1:/usr/share/elasticsearch/data  
ports:  
- 9200:9200

volumes:  
esdata1:  
driver: local

When all three containers start I see the following errors in terminal and I am not able to reach Kibana:

kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:05:12Z","tags":["warning","elasticsearch","admin"],"pid":7,"message":"No living connections"}  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:05:12Z","tags":["warning","elasticsearch","admin"],"pid":7,"message":"Unable to revive connection: [http://elasticsearch:9200/](http://elasticsearch:9200/)"}

[2017-04-08T20:05:27,517][INFO][o.e.n.Node] [hJd3Yol] started  
[2017-04-08T20:05:39,047][ERROR][o.e.x.m.c.i.IndicesStatsCollector] [hJd3Yol] collector [indices-stats-collector] failed to collect data  
org.elasticsearch.cluster.block.ClusterBlockException: blocked by: [SERVICE\_UNAVAILABLE/1/state not recovered / initialized];  
at org.elasticsearch.cluster.block.ClusterBlocks.globalBlockedException(ClusterBlocks.java:165) ~[elasticsearch-5.3.0.jar:5.3.0]

Does anybody have any ideas about the issue and how it could be resolved? (Below are some more logs if needed)  
Thanks.

elasticsearch\_1 | [2017-04-08T20:18:25,685][INFO][o.e.x.s.t.n.SecurityNetty4HttpServerTransport] [hJd3Yol] publish\_address {172.19.0.2:9200}, bound\_addresses {[::]:9200}  
elasticsearch\_1 | [2017-04-08T20:18:25,942][INFO][o.e.n.Node] [hJd3Yol] started  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:18:30Z","tags":["status","plugin:xpack\_main@5.3.0","error"],"pid":6,"state":"red","message":"Status changed from red to red - Request Timeout after 3000ms","prevState":"red","prevMsg":"Unable to connect to Elasticsearch at [http://elasticsearch:9200](http://elasticsearch:9200)."}  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:18:30Z","tags":["status","plugin:graph@5.3.0","error"],"pid":6,"state":"red","message":"Status changed from red to red - Request Timeout after 3000ms","prevState":"red","prevMsg":"Unable to connect to Elasticsearch at [http://elasticsearch:9200](http://elasticsearch:9200)."}  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:18:30Z","tags":["status","plugin:reporting@5.3.0","error"],"pid":6,"state":"red","message":"Status changed from red to red - Request Timeout after 3000ms","prevState":"red","prevMsg":"Unable to connect to Elasticsearch at [http://elasticsearch:9200](http://elasticsearch:9200)."}  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:18:30Z","tags":["status","plugin:security@5.3.0","error"],"pid":6,"state":"red","message":"Status changed from red to red - Request Timeout after 3000ms","prevState":"red","prevMsg":"Unable to connect to Elasticsearch at [http://elasticsearch:9200](http://elasticsearch:9200)."}  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:18:30Z","tags":["status","plugin:searchprofiler@5.3.0","error"],"pid":6,"state":"red","message":"Status changed from red to red - Request Timeout after 3000ms","prevState":"red","prevMsg":"Unable to connect to Elasticsearch at [http://elasticsearch:9200](http://elasticsearch:9200)."}  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:18:30Z","tags":["status","plugin:tilemap@5.3.0","error"],"pid":6,"state":"red","message":"Status changed from red to red - Request Timeout after 3000ms","prevState":"red","prevMsg":"Unable to connect to Elasticsearch at [http://elasticsearch:9200](http://elasticsearch:9200)."}  
kibana\_1 | {"type":"log","@timestamp":"2017-04-08T20:18:30Z","tags":["status","plugin:elasticsearch@5.3.0","error"],"pid":6,"state":"red","message":"Status changed from red to red - Request Timeout after 3000ms","prevState":"red","prevMsg":"Unable to connect to Elasticsearch at [http://elasticsearch:9200](http://elasticsearch:9200)."}  
elasticsearch\_1 | [2017-04-08T20:18:39,714][ERROR][o.e.x.m.c.i.IndicesStatsCollector] [hJd3Yol] collector [indices-stats-collector] failed to collect data  
elasticsearch\_1 | org.elasticsearch.cluster.block.ClusterBlockException: blocked by: [SERVICE\_UNAVAILABLE/1/state not recovered / initialized];  
elasticsearch\_1 | at org.elasticsearch.cluster.block.ClusterBlocks.globalBlockedException(ClusterBlocks.java:165) ~[elasticsearch-5.3.0.jar:5.3.0]  
elasticsearch\_1 | at org.elasticsearch.action.admin.indices.stats.TransportIndicesStatsAction.checkGlobalBlock(TransportIndicesStatsAction.java:70) ~[elasticsearch-5.3.0.jar:5.3.0]

---

<div class="post-metadata">

**Author:** ![Marius\_Dragomir](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/marius_dragomir/32/42087_2.png) [@Marius\_Dragomir](https://discuss.elastic.co/u/Marius_Dragomir)\
**Post date:** [April 10, 2017, 5:22pm UTC](https://discuss.elastic.co/t/elasticsearch-logstash-and-kibana-with-docker-compose/81689/2 "2017-04-10T17:22:45Z")

</div>

You should remove the "Links" param from the docker-compose file as that sets the address where the container can be accessed and right now you're setting it as "elasticsearch" for all 3 containers.

> **[Compose file version 3 reference](https://docs.docker.com/compose/compose-file/#links)**
>
> Reference and guidelines These topics describe version 3 of the Compose file format. This is the newest version. Compose and Docker compatibility matrix There are several versions of the Compose...

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [May 8, 2017, 5:33pm UTC](https://discuss.elastic.co/t/elasticsearch-logstash-and-kibana-with-docker-compose/81689/3 "2017-05-08T17:33:55Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
