# Multiple clients and parallel deployment on ec2 node and

**URL:** <https://discuss.elastic.co/t/multiple-clients-and-parallel-deployment-on-ec2-node-and/7166>\
**Category:** Elasticsearch\
**Created:** [March 28, 2012, 4:16pm UTC](https://discuss.elastic.co/t/multiple-clients-and-parallel-deployment-on-ec2-node-and/7166 "2012-03-28T16:16:30Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![danpolites](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/danpolites/32/2136_2.png) [@danpolites](https://discuss.elastic.co/u/danpolites)\
**Post date:** [March 28, 2012, 4:16pm UTC](https://discuss.elastic.co/t/multiple-clients-and-parallel-deployment-on-ec2-node-and/7166/1 "2012-03-28T16:16:30Z")

</div>

We have two Grails applications that we have installed on one of our EC2  
boxes, both running under the same Tomcat instance. The applications make  
use of a search client with data set to false. They both need to talk to  
the same cluster. The idea was that we would just install these two  
applications on the same box for QA purposes, but it doesn't appear that  
the two applications play well together within the cluster. The first  
application that is deployed works fine, the second one throws a  
MasterNodeNotDiscovered exception. I noticed this recently when trying to  
do parallel deployments as well (Something we were able to do around  
version 0.16.x when we were testing parallel deployments). Is there a way  
to get many client nodes to work within the same cluster on the same  
machine?

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [March 29, 2012, 2:06pm UTC](https://discuss.elastic.co/t/multiple-clients-and-parallel-deployment-on-ec2-node-and/7166/2 "2012-03-29T14:06:13Z")

</div>

Two clients on the same machine will work well. Note though, if oyu start  
two node clients, the first will use port 9300, and the second will use  
port 9301, so maybe you don't have it open?

Also, when creating the ndoe client, mark it as node.client set to true (or  
simply call client(true) on the NodeBuilder). Just setting it to non data  
node means is might still be elected to be a master.

On Wed, Mar 28, 2012 at 6:16 PM, danpolites [dpolites@gmail.com](mailto:dpolites@gmail.com) wrote:

> We have two Grails applications that we have installed on one of our EC2  
> boxes, both running under the same Tomcat instance. The applications make  
> use of a search client with data set to false. They both need to talk to  
> the same cluster. The idea was that we would just install these two  
> applications on the same box for QA purposes, but it doesn't appear that  
> the two applications play well together within the cluster. The first  
> application that is deployed works fine, the second one throws a  
> MasterNodeNotDiscovered exception. I noticed this recently when trying to  
> do parallel deployments as well (Something we were able to do around  
> version 0.16.x when we were testing parallel deployments). Is there a way  
> to get many client nodes to work within the same cluster on the same  
> machine?

---

<div class="post-metadata">

**Author:** ![danpolites](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/danpolites/32/2136_2.png) [@danpolites](https://discuss.elastic.co/u/danpolites)\
**Post date:** [March 30, 2012, 2:34am UTC](https://discuss.elastic.co/t/multiple-clients-and-parallel-deployment-on-ec2-node-and/7166/3 "2012-03-30T02:34:11Z")

</div>

You nailed it. We only had 9300 opened on our security group. We had a  
range of 9300-9400 in the past when we were testing parallel deployments,  
which is why it worked then. Thanks!

---

<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, 3:34am UTC](https://discuss.elastic.co/t/multiple-clients-and-parallel-deployment-on-ec2-node-and/7166/4 "2017-07-06T03:34:10Z")

</div>

Closed on July 6, 2017, 3:34am UTC


