Yesterday I found one of my sites having some wrong search results returned, many strange entries appeared. I did rebuild the whole index and things went fine. But then, another new site within the local network shown the similar problem, it uses Elasticsearch too. I decided to reindex the site just like the previous one, similar result achieved.
After some further stupid moves and checks, I recognized that the two search engine used same index database.
Everything (almost) suddenly came back, they are nodes inside a cluster, automatically, without my intention.
Here are things after all of above:
- New Elasticsearch installation has 'elasticsearch' as default cluster name
- Running services/daemons automatically search for other nodes inside local network
- Nodes with the same cluster name made cluster
- To list and check stats of linked nodes within a cluster:
curl -XGET 'http://localhost:9200/_cluster/nodes/stats'
- Read more about discovery module of Elasticsearch here:
http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/modules-discovery.html