I believe you are running into this: https://github.com/elastic/elasticsearch/pull/24099
We made it so we double-check whether
path.data are set and
hope to verify that we are not writing shard data to both.
network.host setting may have seemed like the culprit, I believe it is how
you are setting
path.data that is the problem. Did you run Elasticsearch with default settings, index data, and then change
path.data by chance?
Steps for how I reproduce this problem to illustrate using a fresh install of Elasticsearch
- run Elasticsearch with the default
default.data.path, in the package's case it is
- index data
curl -XPUT 'localhost:9200/twitter/tweet/1' -H 'Content-Type: application/json' -d'
"user" : "kimchy",
"post_date" : "2009-11-15T14:12:12",
"message" : "trying out Elasticsearch"
- Run Elasticsearch with a
data.path that is different to
default.data.path, but explicitely set the default path (once again, this is being done for you in the packaging)
bin/elasticsearch -Edefault.path.data=/tmp/data -Epath.data=/tmp/different_path
[2017-08-10T11:20:30,607][INFO ][o.e.n.Node ] index folder [6td_4mpERZOtJ8DvVyPU4w] in default.path.data [/tmp/data/no$es/0/indices] must be moved to any of [/tmp/different_path/nodes/0/indices]
[2017-08-10T11:20:30,614][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler]  uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: java.lang.IllegalStateException: detected index data in default.path.data [/tmp/data] $here there should not be any; check the logs for details
Double check you are writing your data to the correct directory