# Docker Elasticsearch 6.4.0 and Logstash

**URL:** <https://discuss.elastic.co/t/docker-elasticsearch-6-4-0-and-logstash/148438>\
**Category:** Elasticsearch\
**Created:** [September 13, 2018, 11:14am UTC](https://discuss.elastic.co/t/docker-elasticsearch-6-4-0-and-logstash/148438 "2018-09-13T11:14:34Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![swild2](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/swild2/32/35512_2.png) [@swild2](https://discuss.elastic.co/u/swild2)\
**Post date:** [September 13, 2018, 11:14am UTC](https://discuss.elastic.co/t/docker-elasticsearch-6-4-0-and-logstash/148438/1 "2018-09-13T11:14:34Z")

</div>

Hey there,  
I'm very new to Docker and Elasticsearch so I hope you can help me.

I created a ES Cluster with 5 nodes (2x dedicated master nodes, 2 data/ingest nodes and one coordinate node). My containers look like:  
es\_master01 0.0.0.0:9201-\>9200/tcp 9300/tcp  
es\_master02 0.0.0.0:9202-\>9200/tcp 9300/tcp  
es\_data01 0.0.0.0:9203-\>9200/tcp 9300/tcp  
es\_data02 0.0.0.0:9204-\>9200/tcp 9300/tcp  
es\_client01 0.0.0.0:9200-\>9200/tcp 9300/tcp

When I do a curl [http://localhost:9200/\_cat/health](http://localhost:9200/_cat/health) I get following output:  
1536836917 11:08:37 elastic\_cluster green 5 2 0 0 0 0 0 0 - 100.0%

And on curl [http://localhost:9200/\_cat/nodes](http://localhost:9200/_cat/nodes) this one:  
172.18.0.3 31 28 2 0.21 0.21 0.71 m - es\_master02  
172.18.0.6 47 28 2 0.21 0.21 0.71 - - es\_client01  
172.18.0.2 29 28 2 0.21 0.21 0.71 m \* es\_master01  
172.18.0.5 24 28 2 0.21 0.21 0.71 di - es\_data02  
172.18.0.4 32 28 2 0.21 0.21 0.71 di - es\_data01

After that I setup a container with logstash and opened a new pipeline with a TCP input and a output to Elasticsearch wich looks like:  
input {  
tcp {  
port =\> 1234  
}  
}  
output {  
elasticsearch {  
hosts =\> ["http://es\_data01:9200","http://es\_data02:9200"]  
index =\> "test\_tcp-%{+YYYY.MM.dd}"  
}  
}

But the expected index is not created. Pinging between the nodes is no problem. Do you have any idea where to search for a solution?

Thanks a lot

Stephan

EDIT:  
I created another output:  
file {  
path =\> "/tmp/test-%{+YYYY.MM.dd}"  
}

and this works fine. So I think it's a problem of networking or elasticsearch.

---

<div class="post-metadata">

**Author:** ![swild2](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/swild2/32/35512_2.png) [@swild2](https://discuss.elastic.co/u/swild2)\
**Post date:** [September 13, 2018, 3:26pm UTC](https://discuss.elastic.co/t/docker-elasticsearch-6-4-0-and-logstash/148438/2 "2018-09-13T15:26:36Z")

</div>

Problem is solved!  
Logstash will not send to an elasticsearch node with a "\_" in the name...

---

<div class="post-metadata">

**Author:** ![jarpy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jarpy/32/51290_2.png) [@jarpy](https://discuss.elastic.co/u/jarpy)\
**Post date:** [September 14, 2018, 3:15am UTC](https://discuss.elastic.co/t/docker-elasticsearch-6-4-0-and-logstash/148438/3 "2018-09-14T03:15:36Z")

</div>

Glad you found it!

It's worth mentioning that underscores are forbidden in hostnames in general (RFC 952).

---

<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:** [October 12, 2018, 3:24am UTC](https://discuss.elastic.co/t/docker-elasticsearch-6-4-0-and-logstash/148438/4 "2018-10-12T03:24:33Z")

</div>

Closed on October 12, 2018, 3:24am UTC

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