# How to create 2 elasticsearch cluster instances on two machine

**URL:** <https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201>\
**Category:** Elasticsearch\
**Created:** [June 19, 2014, 6:28am UTC](https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201 "2014-06-19T06:28:59Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![jonbondash](https://avatars.discourse-cdn.com/v4/letter/j/ecc23a/32.png) [@jonbondash](https://discuss.elastic.co/u/jonbondash)\
**Post date:** [June 19, 2014, 6:28am UTC](https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201/1 "2014-06-19T06:28:59Z")

</div>

Good morning

Can anyone guide me how to setup 2 or more instances of ElasticSearch  
Cluster on two different window server machine on same network?

Thanks & Regards,  
Jonbon Dash

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![Kartavya](https://avatars.discourse-cdn.com/v4/letter/k/65b543/32.png) [@Kartavya](https://discuss.elastic.co/u/Kartavya)\
**Post date:** [June 19, 2014, 6:46am UTC](https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201/2 "2014-06-19T06:46:15Z")

</div>

You can use different cluster name.

Thanks,  
Pulkit Agrawal

Sent from my iPhone

On 19-Jun-2014, at 11:58 AM, JONBON DASH [jonbonworld@gmail.com](mailto:jonbonworld@gmail.com) wrote:

> Good morning
> 
> Can anyone guide me how to setup 2 or more instances of Elasticsearch Cluster on two different window server machine on same network?
> 
> ## Thanks & Regards, Jonbon Dash
> 
> You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com).  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/2E02730A-CBD2-4E74-80AD-29406890F51F%40gmail.com](https://groups.google.com/d/msgid/elasticsearch/2E02730A-CBD2-4E74-80AD-29406890F51F%40gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![jonbondash](https://avatars.discourse-cdn.com/v4/letter/j/ecc23a/32.png) [@jonbondash](https://discuss.elastic.co/u/jonbondash)\
**Post date:** [June 19, 2014, 7:52am UTC](https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201/3 "2014-06-19T07:52:26Z")

</div>

Hi Pulkit,

Thanks for the early response.

I want to maintain the same cluster name between two different machine.

For more clarification,

Suppose "NodeA" started with cluster name "elasticsearch\_RM" in machine 1  
as a master and "NodeB" started with same cluster name "elasticsearch\_RM"  
in machine 2 as worker. Both are running in same network.

What setup I need to define in elasticsearch.yml file, so that worker node  
auto-discover the master node? If possible, can you please share some  
sample YML configuration.

Thanks & Regards,  
Jonbon Dash

On Thursday, June 19, 2014 12:16:41 PM UTC+5:30, Kartavya wrote:

> You can use different cluster name.
> 
> Thanks,  
> Pulkit Agrawal
> 
> Sent from my iPhone
> 
> On 19-Jun-2014, at 11:58 AM, JONBON DASH \<[jonbo...@gmail.com](mailto:jonbo...@gmail.com) \<javascript:\>\>  
> wrote:
> 
> Good morning
> 
> Can anyone guide me how to setup 2 or more instances of Elasticsearch  
> Cluster on two different window server machine on same network?
> 
> Thanks & Regards,  
> Jonbon Dash
> 
> --  
> You received this message because you are subscribed to the Google Groups  
> "elasticsearch" group.  
> To unsubscribe from this group and stop receiving emails from it, send an  
> email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com) \<javascript:\>.  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com)  
> [https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [June 19, 2014, 8:02am UTC](https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201/4 "2014-06-19T08:02:34Z")

</div>

Have a search for unicast zen discovery in the docs and you will be good to  
go.

Regards,  
Mark Walkom

Infrastructure Engineer  
Campaign Monitor  
email: [markw@campaignmonitor.com](mailto:markw@campaignmonitor.com)  
web: [www.campaignmonitor.com](http://www.campaignmonitor.com)

On 19 June 2014 17:52, JONBON DASH [jonbonworld@gmail.com](mailto:jonbonworld@gmail.com) wrote:

> Hi Pulkit,
> 
> Thanks for the early response.
> 
> I want to maintain the same cluster name between two different machine.
> 
> For more clarification,
> 
> Suppose "NodeA" started with cluster name "elasticsearch\_RM" in machine 1  
> as a master and "NodeB" started with same cluster name "elasticsearch\_RM"  
> in machine 2 as worker. Both are running in same network.
> 
> What setup I need to define in elasticsearch.yml file, so that worker node  
> auto-discover the master node? If possible, can you please share some  
> sample YML configuration.
> 
> Thanks & Regards,  
> Jonbon Dash
> 
> On Thursday, June 19, 2014 12:16:41 PM UTC+5:30, Kartavya wrote:
> 
> > You can use different cluster name.
> > 
> > Thanks,  
> > Pulkit Agrawal
> > 
> > Sent from my iPhone
> > 
> > On 19-Jun-2014, at 11:58 AM, JONBON DASH [jonbo...@gmail.com](mailto:jonbo...@gmail.com) wrote:
> > 
> > Good morning
> > 
> > Can anyone guide me how to setup 2 or more instances of Elasticsearch  
> > Cluster on two different window server machine on same network?
> > 
> > Thanks & Regards,  
> > Jonbon Dash
> > 
> > --  
> > You received this message because you are subscribed to the Google Groups  
> > "elasticsearch" group.  
> > To unsubscribe from this group and stop receiving emails from it, send an  
> > email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com).  
> > To view this discussion on the web visit [https://groups.google.com/d/](https://groups.google.com/d/)  
> > msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%  
> > [40googlegroups.com](http://40googlegroups.com)  
> > [https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com?utm_medium=email&utm_source=footer)  
> > .  
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > 
> > --  
> > You received this message because you are subscribed to the Google Groups  
> > "elasticsearch" group.  
> > To unsubscribe from this group and stop receiving emails from it, send an  
> > email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> > To view this discussion on the web visit  
> > [https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com)  
> > [https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com?utm_medium=email&utm_source=footer)  
> > .  
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAEM624biJ85rKcaATgWnChsEPNConmoCcbdjGi-Qgq3NUQai8A%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAEM624biJ85rKcaATgWnChsEPNConmoCcbdjGi-Qgq3NUQai8A%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![jonbondash](https://avatars.discourse-cdn.com/v4/letter/j/ecc23a/32.png) [@jonbondash](https://discuss.elastic.co/u/jonbondash)\
**Post date:** [June 19, 2014, 10:42am UTC](https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201/5 "2014-06-19T10:42:15Z")

</div>

Hi Mark,

I have tried with unicast zen discovery, but i am getting exception "_failed  
to send join request to master_".

This is the below configuration I set in elasticsearch.yml

NodeA:(192.168.19.102)  
cluster.name: elasticsearch\_RM  
node.name: "Elasticsearch1"  
node.master: true  
node.data: true  
transport.tcp.port: 9301  
http.port: 9201

output:

_[2014-06-19 16:00:15,572][INFO][cluster.service]  
[Elasticsearch1] new\_master  
[Elasticsearch1][fStA\_GANTZaiel\_RREBAMg][DC-NG-01][inet[/192.168.19.102:9301]]{master=true},_

- reason: zen-disco-join (elected\_as\_master)\*

NodeB: (192.168.19.105)  
cluster.name: elasticsearch\_RM  
node.name: "Elasticsearch2"  
node.master: false  
node.data: true  
transport.tcp.port: 9302  
http.port: 9202  
gateway.expected\_nodes: 2  
discovery.zen.minimum\_master\_nodes: 1  
discovery.zen.ping.multicast.enabled: false  
discovery.zen.ping.unicast.hosts: ["192.168.19.102:9301"]

output:

_failed to send join request to master  
[[Elasticsearch1][fStA\_GANTZaiel\_RREBAMg][DC-NG-01][inet[/192.168.19.102:9301]]{master=true}],  
reason [org.elasticsearch.ElasticsearchTimeoutException: Timeout waiting  
for task.]_

Please let me know, if any configuration I have missed.

Thanks & Regards,  
Jonbon Dash

On Thu, Jun 19, 2014 at 1:32 PM, Mark Walkom [markw@campaignmonitor.com](mailto:markw@campaignmonitor.com)  
wrote:

> Have a search for unicast zen discovery in the docs and you will be good  
> to go.
> 
> Regards,  
> Mark Walkom
> 
> Infrastructure Engineer  
> Campaign Monitor  
> email: [markw@campaignmonitor.com](mailto:markw@campaignmonitor.com)  
> web: [www.campaignmonitor.com](http://www.campaignmonitor.com)
> 
> On 19 June 2014 17:52, JONBON DASH [jonbonworld@gmail.com](mailto:jonbonworld@gmail.com) wrote:
> 
> > Hi Pulkit,
> > 
> > Thanks for the early response.
> > 
> > I want to maintain the same cluster name between two different machine.
> > 
> > For more clarification,
> > 
> > Suppose "NodeA" started with cluster name "elasticsearch\_RM" in machine 1  
> > as a master and "NodeB" started with same cluster name "elasticsearch\_RM"  
> > in machine 2 as worker. Both are running in same network.
> > 
> > What setup I need to define in elasticsearch.yml file, so that worker  
> > node auto-discover the master node? If possible, can you please share some  
> > sample YML configuration.
> > 
> > Thanks & Regards,  
> > Jonbon Dash
> > 
> > On Thursday, June 19, 2014 12:16:41 PM UTC+5:30, Kartavya wrote:
> > 
> > > You can use different cluster name.
> > > 
> > > Thanks,  
> > > Pulkit Agrawal
> > > 
> > > Sent from my iPhone
> > > 
> > > On 19-Jun-2014, at 11:58 AM, JONBON DASH [jonbo...@gmail.com](mailto:jonbo...@gmail.com) wrote:
> > > 
> > > Good morning
> > > 
> > > Can anyone guide me how to setup 2 or more instances of Elasticsearch  
> > > Cluster on two different window server machine on same network?
> > > 
> > > Thanks & Regards,  
> > > Jonbon Dash
> > > 
> > > --  
> > > You received this message because you are subscribed to the Google  
> > > Groups "elasticsearch" group.  
> > > To unsubscribe from this group and stop receiving emails from it, send  
> > > an email to [elasticsearc...@googlegroups.com](mailto:elasticsearc...@googlegroups.com).  
> > > To view this discussion on the web visit [https://groups.google.com/d/](https://groups.google.com/d/)  
> > > msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%  
> > > [40googlegroups.com](http://40googlegroups.com)  
> > > [https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/21430aa5-17aa-4aca-b97d-f1f63f6fb4fa%40googlegroups.com?utm_medium=email&utm_source=footer)  
> > > .  
> > > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> > > 
> > > --  
> > > You received this message because you are subscribed to the Google Groups  
> > > "elasticsearch" group.  
> > > To unsubscribe from this group and stop receiving emails from it, send an  
> > > email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).
> > 
> > To view this discussion on the web visit  
> > [https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com)  
> > [https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/c048ac6a-cde9-4917-8559-149db5f7da64%40googlegroups.com?utm_medium=email&utm_source=footer)  
> > .  
> > For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).
> 
> --  
> You received this message because you are subscribed to a topic in the  
> Google Groups "elasticsearch" group.  
> To unsubscribe from this topic, visit  
> [https://groups.google.com/d/topic/elasticsearch/4bxlrRX-ZbA/unsubscribe](https://groups.google.com/d/topic/elasticsearch/4bxlrRX-ZbA/unsubscribe).  
> To unsubscribe from this group and all its topics, send an email to  
> [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/CAEM624biJ85rKcaATgWnChsEPNConmoCcbdjGi-Qgq3NUQai8A%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAEM624biJ85rKcaATgWnChsEPNConmoCcbdjGi-Qgq3NUQai8A%40mail.gmail.com)  
> [https://groups.google.com/d/msgid/elasticsearch/CAEM624biJ85rKcaATgWnChsEPNConmoCcbdjGi-Qgq3NUQai8A%40mail.gmail.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/CAEM624biJ85rKcaATgWnChsEPNConmoCcbdjGi-Qgq3NUQai8A%40mail.gmail.com?utm_medium=email&utm_source=footer)  
> .
> 
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CABk0ASnLxYdogV%3D\_\_yXw-\_-KpvpxZz8XMRU9kot\_aq5%2BrPtGbw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CABk0ASnLxYdogV%3D__yXw-_-KpvpxZz8XMRU9kot_aq5%2BrPtGbw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 1:21am UTC](https://discuss.elastic.co/t/how-to-create-2-elasticsearch-cluster-instances-on-two-machine/18201/6 "2017-07-06T01:21:14Z")

</div>


