I have one VPS running two PHP applications (resp. production and test/staging environment of one application) that are using Elasticsearch. Until now I only had one cluster with one node, that was shared between both apps (at port 9200). I now need to separate the ES for each app, so I could use different data, indexes, mappings etc. for each of them. And I would still like to run everything on single VPS.
With Puppet I was able to set up two nodes listening at port 9200 and 9201 (two services), but they still seem to be dependent on each other – if I update mapping on one, the other app crashes (without logging anything, that's why it's so hard to debugg). I also tried using different cluster.name
for each of them, but the the second cluster has UUID: _na_
and updating mapping and data doesn't work.
I'm new to ES so I'll appreciate any noob help, best practices or pointing in correct direction.
Edit
elasticsearch.yml
configs:
cluster.name: my-production-cluster
http.port: 9200
node.name: my-production-node
path.data: "/var/lib/elasticsearch/my-production"
path.logs: "/var/log/elasticsearch/my-production"
cluster.name: my-test-cluster
http.port: 9201
node.name: my-test-node
path.data: "/var/lib/elasticsearch/my-test"
path.logs: "/var/log/elasticsearch/my-test"
I was able to debug a bit more and the second one is throwing master_not_discovered_exception
error with 503 code.