Gce plugin configuration as command arguments


For various reasons I have to run multiple elasticsearch cluster instances within the same boxes therefore I spin up each cluster as a command line with configurable arguments. I need to configure the gce plugin for autodiscovery. Any suggestion how to do that?

Thanks in advance.

You can't really do that.

GCE plugin expects only one machine running.

Related: https://www.elastic.co/guide/en/elasticsearch/plugins/current/cloud-gce-usage-discovery-port.html

Thanks, I actually find out that the issue I am having is not related to autodiscovery. For some reason I have a number of unallocated shards. Since at the first glance all the unallocated shards were from the same nodes I assumed that the autodiscovery is not working. Now I need to figure out how to fix the unallocated shards thing.

If I set the number of replicas to 0 that mean no replication then there are no unallocated shards but as soon as I increase the number of replications the unallocated shards would pop up.

Any suggestions?

Do you have more than one data node? if not you will always have a yellow condition as the replica cannot be on the same node as data?
I had that same problem when I first started learning Elasticsearch with a one node cluster.

I am running a 3 node cluster, I do not specify the number of the data nodes. Therefore I am assuming that all the nodes are data nodes.