Now, I am able to run ElasticSearch cluster of multiple 'WORKER' nodes and
with only one single 'MASTER' node.
This was resolved by configuring it in "configuration/elasticsearch.xml" as
follows :
<property>
<name>discovery.zen.ping.unicast.hosts</name>
<value>
["${@//site/global/elasticsearchmaster_host}:${@//site/global/master_tcp_port}"]
</value>
<description></description>
</property>
Putting above config in app_config itself does not work because
"${@//site/global/master_tcp_port}"
been converted to "${ELASTICSEARCHMASTER.ALLOCATED_PORT}" first and try to
allocate dynamic ports which results in different ports for
"site.global.master_tcp_port"
and "discovery.zen.ping.unicast.hosts". Hence I moved it to
"configuration/elasticsearch.xml"
which works fine for me with single MASTER instance.
It does not work with 2 or more MASTER nodes,
Now I want to know how I need to configure in order to have multiple MASTER
nodes with its ports, when I tried running for 2 instances, it resulted as
"host1, host2:port2" but what I expect is "host1:port1, host2:port2".
Please help me in resolving this. Thanks in advance.
Thanks,
Chackra
On Mon, Jun 22, 2015 at 2:50 PM, Steve Loughran <[email protected]>
wrote:
> I guess we have to make sure that the .py launcher scripts are allocating
> those ports and setting the properties.
>
> Gour -got any ideas?
>
>
> > On 21 Jun 2015, at 19:57, Chackravarthy Esakkimuthu <
> [email protected]> wrote:
> >
> > I tried creating slider app-package for ElasticSearch, and able to do it
> > for single node ES cluster. It works for single instance of a component.
> >
> > But facing some issue when forming a cluster of 2 or more nodes for
> which I
> > need to have master host and port details to be available in the
> > elasticsearch.yml which I am not able to create it properly.
> >
> > Consider am having 2 components for this, ELASTICSEARCHMASTER (3
> instances)
> > and ELASTICSEARCHWORKER (2 instances)
> >
> > To form a cluster, I need to have a property named
> >
> > "discovery.zen.ping.unicast.hosts":"ES_MASTER_HOST_1:TCP_PORT_1,
> > ES_MASTER_HOST_2:TCP_PORT_2, ES_MASTER_HOST_2:TCP_PORT_3"
> >
> > This config is required for all instances for both the components as
> well,
> > how do I do it? I tried with some combination, but could not get the
> > correct one which I need.
> >
> > If only hostnames, then able to do it using ${ELASTICSEARCHMASTER_HOST}
> > which populates all 3 master hosts, but I want to populate it with hosts
> +
> > port as well.
> >
> > ################### app-config.json ###################
> >
> > "site.global.master_tcp_port": "${ELASTICSEARCHMASTER.ALLOCATED_PORT}",
> >
> > "site.elasticsearch.discovery.zen.ping.unicast.hosts": "??",
> > ################### app-config.json ###################
> >
> > Thanks,
> > Chackra
>
>