# Java client can't start a node

**URL:** <https://discuss.elastic.co/t/java-client-cant-start-a-node/9661>\
**Category:** Elasticsearch\
**Created:** [November 10, 2012, 10:28pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661 "2012-11-10T22:28:50Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![Slava\_G](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@Slava\_G](https://discuss.elastic.co/u/Slava_G)\
**Post date:** [November 10, 2012, 10:28pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/1 "2012-11-10T22:28:50Z")

</div>

Hi,  
Trying simple java client sample :  
Node node = nodeBuilder().client(true).node();  
Client client = node.client();

With clean elasticsearch 0.19.9, without any changes to configuration  
In the past, it was working fine, but now I'm getting in the elasticsearch  
console :

[2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom Boy]  
received ping response ping\_response{target [[Boom  
Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
Boy][do472RNfRry9KY5Y-t1vaQ  
][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no matching id  
[144]

and then in the java :  
Exception in thread "main"  
org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]  
at  
org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)  
at  
org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)  
at  
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)  
at  
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)  
at java.lang.Thread.run(Thread.java:722)

Thanks.

--

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [November 11, 2012, 1:51pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/2 "2012-11-11T13:51:53Z")

</div>

It seems that the other node you are trying to connect to is not up.

That’s the way I understand your stacktrace.

I think that when you use a client node, you must have a running data node  
elsewhere.

HTH

David

De : [elasticsearch@googlegroups.com](mailto:elasticsearch@googlegroups.com) [[mailto:elasticsearch@googlegroups.com](mailto:elasticsearch@googlegroups.com)]  
De la part de slavag  
Envoyé : samedi 10 novembre 2012 23:29  
À : [elasticsearch@googlegroups.com](mailto:elasticsearch@googlegroups.com)  
Objet : Java client can't start a node

Hi,

Trying simple java client sample :

Node node = nodeBuilder().client(true).node();

Client client = node.client();

With clean elasticsearch 0.19.9, without any changes to configuration

In the past, it was working fine, but now I'm getting in the elasticsearch  
console :

[2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom Boy]  
received ping response ping\_response{target [[Boom  
Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
Boy][do472RNfRry9KY5Y-t1vaQ

][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no matching id  
[144]

and then in the java :

Exception in thread "main"  
org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]

```
      at

```

org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3  
.onTimeout(TransportMasterNodeOperationAction.java:169)

```
      at

```

org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(I  
nternalClusterService.java:356)

```
      at

```

java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:11  
10)

```
      at

```

java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:6  
03)

```
      at java.lang.Thread.run(Thread.java:722)

```

Thanks.

--

--

---

<div class="post-metadata">

**Author:** ![Slava\_G](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@Slava\_G](https://discuss.elastic.co/u/Slava_G)\
**Post date:** [November 11, 2012, 2:06pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/3 "2012-11-11T14:06:01Z")

</div>

Hi David,  
Actually the elasticsearch is running on the same machine where I'm trying  
to run java.  
The elasticsearch is only one node and it's a master node, so I guess it's  
a data node.

Thanks.

On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:

> It seems that the other node you are trying to connect to is not up.
> 
> That’s the way I understand your stacktrace.
> 
> I think that when you use a client node, you must have a running data node  
> elsewhere.
> 
> HTH
> 
> David
> 
> _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) \<javascript:\> [mailto:  
> [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) \<javascript:\>] _De la part de_ slavag  
> _Envoyé :_ samedi 10 novembre 2012 23:29  
> _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) \<javascript:\>  
> _Objet :_ Java client can't start a node
> 
> Hi,
> 
> Trying simple java client sample :
> 
> Node node = nodeBuilder().client(true).node();
> 
> Client client = node.client();
> 
> With clean elasticsearch 0.19.9, without any changes to configuration
> 
> In the past, it was working fine, but now I'm getting in the elasticsearch  
> console :
> 
> [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom Boy]  
> received ping response ping\_response{target [[Boom  
> Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> Boy][do472RNfRry9KY5Y-t1vaQ
> 
> ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no matching  
> id [144]
> 
> and then in the java :
> 
> Exception in thread "main"  
> org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> 
> ```
> at 
> 
> ```
> 
> org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> 
> ```
> at 
> 
> ```
> 
> org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> 
> ```
> at 
> 
> ```
> 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> 
> ```
> at 
> 
> ```
> 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> 
> ```
> at java.lang.Thread.run(Thread.java:722)
> 
> ```
> 
> Thanks.
> 
> --

--

---

<div class="post-metadata">

**Author:** ![jprante](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jprante/32/44941_2.png) [@jprante](https://discuss.elastic.co/u/jprante)\
**Post date:** [November 12, 2012, 8:08am UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/4 "2012-11-12T08:08:08Z")

</div>

You are not giving us the full log trace with the error cause. Please  
switch your log level into DEBUG or TRACE mode, restart the ES node again,  
and try your client to connect. You will see the full error in the logs.

Possible reasons I can think of: network interface setup, ES network  
configuration, cluster name mismatch, zen discovery timeout

Best regards,

Jörg

On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:

> Hi David,  
> Actually the elasticsearch is running on the same machine where I'm trying  
> to run java.  
> The elasticsearch is only one node and it's a master node, so I guess it's  
> a data node.
> 
> Thanks.
> 
> On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> 
> > It seems that the other node you are trying to connect to is not up.
> > 
> > That’s the way I understand your stacktrace.
> > 
> > I think that when you use a client node, you must have a running data  
> > node elsewhere.
> > 
> > HTH
> > 
> > David
> > 
> > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)] _De  
> > la part de_ slavag  
> > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > _Objet :_ Java client can't start a node
> > 
> > Hi,
> > 
> > Trying simple java client sample :
> > 
> > Node node = nodeBuilder().client(true).node();
> > 
> > Client client = node.client();
> > 
> > With clean elasticsearch 0.19.9, without any changes to configuration
> > 
> > In the past, it was working fine, but now I'm getting in the  
> > elasticsearch console :
> > 
> > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom Boy]  
> > received ping response ping\_response{target [[Boom  
> > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > Boy][do472RNfRry9KY5Y-t1vaQ
> > 
> > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no matching  
> > id [144]
> > 
> > and then in the java :
> > 
> > Exception in thread "main"  
> > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > 
> > ```
> > at 
> > 
> > ```
> > 
> > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > 
> > ```
> > at 
> > 
> > ```
> > 
> > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > 
> > ```
> > at 
> > 
> > ```
> > 
> > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > 
> > ```
> > at 
> > 
> > ```
> > 
> > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > 
> > ```
> > at java.lang.Thread.run(Thread.java:722)
> > 
> > ```
> > 
> > Thanks.
> > 
> > --

--

---

<div class="post-metadata">

**Author:** ![Slava\_G](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@Slava\_G](https://discuss.elastic.co/u/Slava_G)\
**Post date:** [November 12, 2012, 8:37pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/5 "2012-11-12T20:37:07Z")

</div>

Hi, Jörg  
I attached log file from the elasticsearch run.  
Thanks,

On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:

> You are not giving us the full log trace with the error cause. Please  
> switch your log level into DEBUG or TRACE mode, restart the ES node again,  
> and try your client to connect. You will see the full error in the logs.
> 
> Possible reasons I can think of: network interface setup, ES network  
> configuration, cluster name mismatch, zen discovery timeout
> 
> Best regards,
> 
> Jörg
> 
> On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> 
> > Hi David,  
> > Actually the elasticsearch is running on the same machine where I'm  
> > trying to run java.  
> > The elasticsearch is only one node and it's a master node, so I guess  
> > it's a data node.
> > 
> > Thanks.
> > 
> > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > 
> > > It seems that the other node you are trying to connect to is not up.
> > > 
> > > That’s the way I understand your stacktrace.
> > > 
> > > I think that when you use a client node, you must have a running data  
> > > node elsewhere.
> > > 
> > > HTH
> > > 
> > > David
> > > 
> > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)] _De  
> > > la part de_ slavag  
> > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > _Objet :_ Java client can't start a node
> > > 
> > > Hi,
> > > 
> > > Trying simple java client sample :
> > > 
> > > Node node = nodeBuilder().client(true).node();
> > > 
> > > Client client = node.client();
> > > 
> > > With clean elasticsearch 0.19.9, without any changes to configuration
> > > 
> > > In the past, it was working fine, but now I'm getting in the  
> > > elasticsearch console :
> > > 
> > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom  
> > > Boy] received ping response ping\_response{target [[Boom  
> > > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > > Boy][do472RNfRry9KY5Y-t1vaQ
> > > 
> > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no matching  
> > > id [144]
> > > 
> > > and then in the java :
> > > 
> > > Exception in thread "main"  
> > > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > > 
> > > ```
> > > at 
> > > 
> > > ```
> > > 
> > > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > > 
> > > ```
> > > at 
> > > 
> > > ```
> > > 
> > > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > > 
> > > ```
> > > at 
> > > 
> > > ```
> > > 
> > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > > 
> > > ```
> > > at 
> > > 
> > > ```
> > > 
> > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > > 
> > > ```
> > > at java.lang.Thread.run(Thread.java:722)
> > > 
> > > ```
> > > 
> > > Thanks.
> > > 
> > > --

--

---

<div class="post-metadata">

**Author:** ![jprante](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jprante/32/44941_2.png) [@jprante](https://discuss.elastic.co/u/jprante)\
**Post date:** [November 14, 2012, 8:26am UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/6 "2012-11-14T08:26:49Z")

</div>

Hi,

there is something on your machine which stops your data node immediately  
after ist has been started.

[2012-11-12 15:40:13,733][INFO][node] [Corbo, Jared]  
{0.19.9}[11076]: starting ...  
[2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo, Jared]  
new\_master [Corbo,  
Jared][QJqeSKH0QVWuMIOJyAZFDQ][inet[/10.26.180.190:9300]], reason:  
zen-disco-join (elected\_as\_master)  
[2012-11-12 15:40:17,739][INFO][node] [Corbo, Jared]  
{0.19.9}[11076]: started  
[2012-11-12 15:40:17,776][INFO][node] [Corbo, Jared]  
{0.19.9}[11076]: stopping ...

Next, another node comes up, but this node seems to be a client node.

[2012-11-12 15:40:33,030][INFO][node] [Piper]  
{0.19.9}[8136]: starting ...  
[2012-11-12 15:40:36,302][INFO][cluster.service] [Piper]  
new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]],  
reason: zen-disco-join (elected\_as\_master)  
[2012-11-12 15:40:36,354][DEBUG][transport.netty] [Piper]  
connected to node  
[[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]  
[2012-11-12 15:40:36,469][INFO][node] [Piper]  
{0.19.9}[8136]: started

[2012-11-12 15:42:56,299][DEBUG][transport.netty] [Piper]  
disconnected from  
[[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]

You see, you always start one node at a time, no node detects each other.  
They all use same address and port 10.26.180.190:9300. Starting and  
stopping one node after each other can't work. Check if you can set up a  
server node which stays active, and then connect with a client node, which  
can be recognized by using a different port than 9300 (it should be 9301  
since 9300 is allocated).

Jörg

On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:

> Hi, Jörg  
> I attached log file from the elasticsearch run.  
> Thanks,
> 
> On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:
> 
> > You are not giving us the full log trace with the error cause. Please  
> > switch your log level into DEBUG or TRACE mode, restart the ES node again,  
> > and try your client to connect. You will see the full error in the logs.
> > 
> > Possible reasons I can think of: network interface setup, ES network  
> > configuration, cluster name mismatch, zen discovery timeout
> > 
> > Best regards,
> > 
> > Jörg
> > 
> > On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> > 
> > > Hi David,  
> > > Actually the elasticsearch is running on the same machine where I'm  
> > > trying to run java.  
> > > The elasticsearch is only one node and it's a master node, so I guess  
> > > it's a data node.
> > > 
> > > Thanks.
> > > 
> > > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > > 
> > > > It seems that the other node you are trying to connect to is not up.
> > > > 
> > > > That’s the way I understand your stacktrace.
> > > > 
> > > > I think that when you use a client node, you must have a running data  
> > > > node elsewhere.
> > > > 
> > > > HTH
> > > > 
> > > > David
> > > > 
> > > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)] _De  
> > > > la part de_ slavag  
> > > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > > _Objet :_ Java client can't start a node
> > > > 
> > > > Hi,
> > > > 
> > > > Trying simple java client sample :
> > > > 
> > > > Node node = nodeBuilder().client(true).node();
> > > > 
> > > > Client client = node.client();
> > > > 
> > > > With clean elasticsearch 0.19.9, without any changes to configuration
> > > > 
> > > > In the past, it was working fine, but now I'm getting in the  
> > > > elasticsearch console :
> > > > 
> > > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom  
> > > > Boy] received ping response ping\_response{target [[Boom  
> > > > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > > > Boy][do472RNfRry9KY5Y-t1vaQ
> > > > 
> > > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no  
> > > > matching id [144]
> > > > 
> > > > and then in the java :
> > > > 
> > > > Exception in thread "main"  
> > > > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > > > 
> > > > ```
> > > > at 
> > > > 
> > > > ```
> > > > 
> > > > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > > > 
> > > > ```
> > > > at 
> > > > 
> > > > ```
> > > > 
> > > > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > > > 
> > > > ```
> > > > at 
> > > > 
> > > > ```
> > > > 
> > > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > > > 
> > > > ```
> > > > at 
> > > > 
> > > > ```
> > > > 
> > > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > > > 
> > > > ```
> > > > at java.lang.Thread.run(Thread.java:722)
> > > > 
> > > > ```
> > > > 
> > > > Thanks.
> > > > 
> > > > --

--

---

<div class="post-metadata">

**Author:** ![Slava\_G](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@Slava\_G](https://discuss.elastic.co/u/Slava_G)\
**Post date:** [November 16, 2012, 5:35pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/7 "2012-11-16T17:35:48Z")

</div>

Hi Jörg ,  
The elasticsearch is running as data node (single instance on my computer)  
and client it's a simple java app with one line of code.  
Actually, I don't have any idea what I'm doing wrong as it should be very  
simple, but I spent a week and didn't find any problem that could cause  
this issue.  
The elasticsearch seems to be started and now I don't see any stop  
notification as what before, but my java app failed to connect to the  
elasticsearch.

Thanks.

On Wednesday, November 14, 2012 10:26:49 AM UTC+2, Jörg Prante wrote:

> Hi,
> 
> there is something on your machine which stops your data node immediately  
> after ist has been started.
> 
> [2012-11-12 15:40:13,733][INFO][node] [Corbo, Jared]  
> {0.19.9}[11076]: starting ...  
> [2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo, Jared]  
> new\_master [Corbo,  
> Jared][QJqeSKH0QVWuMIOJyAZFDQ][inet[/10.26.180.190:9300]], reason:  
> zen-disco-join (elected\_as\_master)  
> [2012-11-12 15:40:17,739][INFO][node] [Corbo, Jared]  
> {0.19.9}[11076]: started  
> [2012-11-12 15:40:17,776][INFO][node] [Corbo, Jared]  
> {0.19.9}[11076]: stopping ...
> 
> Next, another node comes up, but this node seems to be a client node.
> 
> [2012-11-12 15:40:33,030][INFO][node] [Piper]  
> {0.19.9}[8136]: starting ...  
> [2012-11-12 15:40:36,302][INFO][cluster.service] [Piper]  
> new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]],  
> reason: zen-disco-join (elected\_as\_master)  
> [2012-11-12 15:40:36,354][DEBUG][transport.netty] [Piper]  
> connected to node  
> [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]  
> [2012-11-12 15:40:36,469][INFO][node] [Piper]  
> {0.19.9}[8136]: started
> 
> [2012-11-12 15:42:56,299][DEBUG][transport.netty] [Piper]  
> disconnected from  
> [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]
> 
> You see, you always start one node at a time, no node detects each other.  
> They all use same address and port 10.26.180.190:9300. Starting and  
> stopping one node after each other can't work. Check if you can set up a  
> server node which stays active, and then connect with a client node, which  
> can be recognized by using a different port than 9300 (it should be 9301  
> since 9300 is allocated).
> 
> Jörg
> 
> On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:
> 
> > Hi, Jörg  
> > I attached log file from the elasticsearch run.  
> > Thanks,
> > 
> > On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:
> > 
> > > You are not giving us the full log trace with the error cause. Please  
> > > switch your log level into DEBUG or TRACE mode, restart the ES node again,  
> > > and try your client to connect. You will see the full error in the logs.
> > > 
> > > Possible reasons I can think of: network interface setup, ES network  
> > > configuration, cluster name mismatch, zen discovery timeout
> > > 
> > > Best regards,
> > > 
> > > Jörg
> > > 
> > > On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> > > 
> > > > Hi David,  
> > > > Actually the elasticsearch is running on the same machine where I'm  
> > > > trying to run java.  
> > > > The elasticsearch is only one node and it's a master node, so I guess  
> > > > it's a data node.
> > > > 
> > > > Thanks.
> > > > 
> > > > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > > > 
> > > > > It seems that the other node you are trying to connect to is not up.
> > > > > 
> > > > > That’s the way I understand your stacktrace.
> > > > > 
> > > > > I think that when you use a client node, you must have a running data  
> > > > > node elsewhere.
> > > > > 
> > > > > HTH
> > > > > 
> > > > > David
> > > > > 
> > > > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)]  
> > > > > _De la part de_ slavag  
> > > > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > > > _Objet :_ Java client can't start a node
> > > > > 
> > > > > Hi,
> > > > > 
> > > > > Trying simple java client sample :
> > > > > 
> > > > > Node node = nodeBuilder().client(true).node();
> > > > > 
> > > > > Client client = node.client();
> > > > > 
> > > > > With clean elasticsearch 0.19.9, without any changes to configuration
> > > > > 
> > > > > In the past, it was working fine, but now I'm getting in the  
> > > > > elasticsearch console :
> > > > > 
> > > > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom  
> > > > > Boy] received ping response ping\_response{target [[Boom  
> > > > > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > > > > Boy][do472RNfRry9KY5Y-t1vaQ
> > > > > 
> > > > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no  
> > > > > matching id [144]
> > > > > 
> > > > > and then in the java :
> > > > > 
> > > > > Exception in thread "main"  
> > > > > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > > > > 
> > > > > ```
> > > > > at 
> > > > > 
> > > > > ```
> > > > > 
> > > > > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > > > > 
> > > > > ```
> > > > > at 
> > > > > 
> > > > > ```
> > > > > 
> > > > > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > > > > 
> > > > > ```
> > > > > at 
> > > > > 
> > > > > ```
> > > > > 
> > > > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > > > > 
> > > > > ```
> > > > > at 
> > > > > 
> > > > > ```
> > > > > 
> > > > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > > > > 
> > > > > ```
> > > > > at java.lang.Thread.run(Thread.java:722)
> > > > > 
> > > > > ```
> > > > > 
> > > > > Thanks.
> > > > > 
> > > > > --

--

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [November 16, 2012, 5:39pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/8 "2012-11-16T17:39:02Z")

</div>

Just wondering if you have something weird with your firewall settings, especially if you run it under windows.

Could you double-check that?

--  
David 😉  
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs

Le 16 nov. 2012 à 18:35, slavag [slavago@gmail.com](mailto:slavago@gmail.com) a écrit :

> Hi Jörg ,  
> The elasticsearch is running as data node (single instance on my computer) and client it's a simple java app with one line of code.  
> Actually, I don't have any idea what I'm doing wrong as it should be very simple, but I spent a week and didn't find any problem that could cause this issue.  
> The elasticsearch seems to be started and now I don't see any stop notification as what before, but my java app failed to connect to the elasticsearch.
> 
> Thanks.
> 
> On Wednesday, November 14, 2012 10:26:49 AM UTC+2, Jörg Prante wrote:  
> Hi,
> 
> there is something on your machine which stops your data node immediately after ist has been started.
> 
> [2012-11-12 15:40:13,733][INFO][node] [Corbo, Jared] {0.19.9}[11076]: starting ...  
> [2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo, Jared] new\_master [Corbo, Jared][QJqeSKH0QVWuMIOJyAZFDQ][inet[/10.26.180.190:9300]], reason: zen-disco-join (elected\_as\_master)  
> [2012-11-12 15:40:17,739][INFO][node] [Corbo, Jared] {0.19.9}[11076]: started  
> [2012-11-12 15:40:17,776][INFO][node] [Corbo, Jared] {0.19.9}[11076]: stopping ...
> 
> Next, another node comes up, but this node seems to be a client node.
> 
> [2012-11-12 15:40:33,030][INFO][node] [Piper] {0.19.9}[8136]: starting ...  
> [2012-11-12 15:40:36,302][INFO][cluster.service] [Piper] new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]], reason: zen-disco-join (elected\_as\_master)  
> [2012-11-12 15:40:36,354][DEBUG][transport.netty] [Piper] connected to node [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]  
> [2012-11-12 15:40:36,469][INFO][node] [Piper] {0.19.9}[8136]: started
> 
> [2012-11-12 15:42:56,299][DEBUG][transport.netty] [Piper] disconnected from [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]
> 
> You see, you always start one node at a time, no node detects each other. They all use same address and port 10.26.180.190:9300. Starting and stopping one node after each other can't work. Check if you can set up a server node which stays active, and then connect with a client node, which can be recognized by using a different port than 9300 (it should be 9301 since 9300 is allocated).
> 
> Jörg
> 
> On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:  
> Hi, Jörg  
> I attached log file from the elasticsearch run.  
> Thanks,
> 
> On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:  
> You are not giving us the full log trace with the error cause. Please switch your log level into DEBUG or TRACE mode, restart the ES node again, and try your client to connect. You will see the full error in the logs.
> 
> Possible reasons I can think of: network interface setup, ES network configuration, cluster name mismatch, zen discovery timeout
> 
> Best regards,
> 
> Jörg
> 
> On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:  
> Hi David,  
> Actually the elasticsearch is running on the same machine where I'm trying to run java.  
> The elasticsearch is only one node and it's a master node, so I guess it's a data node.
> 
> Thanks.
> 
> On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:  
> It seems that the other node you are trying to connect to is not up.
> 
> That’s the way I understand your stacktrace.
> 
> I think that when you use a client node, you must have a running data node elsewhere.
> 
> HTH
> 
> David
> 
> De : [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)] De la part de slavag  
> Envoyé : samedi 10 novembre 2012 23:29  
> À : [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> Objet : Java client can't start a node
> 
> Hi,
> 
> Trying simple java client sample :
> 
> Node node = nodeBuilder().client(true).node();
> 
> Client client = node.client();
> 
> With clean elasticsearch 0.19.9, without any changes to configuration
> 
> In the past, it was working fine, but now I'm getting in the elasticsearch console :
> 
> [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom Boy] received ping response ping\_response{target [[Boom Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom Boy][do472RNfRry9KY5Y-t1vaQ
> 
> ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no matching id [144]
> 
> and then in the java :
> 
> Exception in thread "main" org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> 
> ```
> at org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> 
> at org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> 
> at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> 
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> 
> at java.lang.Thread.run(Thread.java:722)
> 
> ```
> 
> Thanks.
> 
> --
> 
> --

--

---

<div class="post-metadata">

**Author:** ![Igor\_Motov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igor_motov/32/45193_2.png) [@Igor\_Motov](https://discuss.elastic.co/u/Igor_Motov)\
**Post date:** [November 16, 2012, 7:38pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/9 "2012-11-16T19:38:31Z")

</div>

How often does ip address of your machine changes? Could the following  
scenario be your case: you start elasticsearch server, ip changes and then  
start the client and it fails to connect?

On Friday, November 16, 2012 12:39:49 PM UTC-5, David Pilato wrote:

> Just wondering if you have something weird with your firewall settings,  
> especially if you run it under windows.
> 
> Could you double-check that?
> 
> --  
> David 😉  
> Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> 
> Le 16 nov. 2012 à 18:35, slavag \<[sla...@gmail.com](mailto:sla...@gmail.com) \<javascript:\>\> a écrit :
> 
> Hi Jörg ,  
> The elasticsearch is running as data node (single instance on my computer)  
> and client it's a simple java app with one line of code.  
> Actually, I don't have any idea what I'm doing wrong as it should be very  
> simple, but I spent a week and didn't find any problem that could cause  
> this issue.  
> The elasticsearch seems to be started and now I don't see any stop  
> notification as what before, but my java app failed to connect to the  
> elasticsearch.
> 
> Thanks.
> 
> On Wednesday, November 14, 2012 10:26:49 AM UTC+2, Jörg Prante wrote:
> 
> > Hi,
> > 
> > there is something on your machine which stops your data node immediately  
> > after ist has been started.
> > 
> > [2012-11-12 15:40:13,733][INFO][node] [Corbo,  
> > Jared] {0.19.9}[11076]: starting ...  
> > [2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo,  
> > Jared] new\_master [Corbo,  
> > Jared][QJqeSKH0QVWuMIOJyAZFDQ][inet[/10.26.180.190:9300]], reason:  
> > zen-disco-join (elected\_as\_master)  
> > [2012-11-12 15:40:17,739][INFO][node] [Corbo,  
> > Jared] {0.19.9}[11076]: started  
> > [2012-11-12 15:40:17,776][INFO][node] [Corbo,  
> > Jared] {0.19.9}[11076]: stopping ...
> > 
> > Next, another node comes up, but this node seems to be a client node.
> > 
> > [2012-11-12 15:40:33,030][INFO][node] [Piper]  
> > {0.19.9}[8136]: starting ...  
> > [2012-11-12 15:40:36,302][INFO][cluster.service] [Piper]  
> > new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]],  
> > reason: zen-disco-join (elected\_as\_master)  
> > [2012-11-12 15:40:36,354][DEBUG][transport.netty] [Piper]  
> > connected to node  
> > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]  
> > [2012-11-12 15:40:36,469][INFO][node] [Piper]  
> > {0.19.9}[8136]: started
> > 
> > [2012-11-12 15:42:56,299][DEBUG][transport.netty] [Piper]  
> > disconnected from  
> > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]
> > 
> > You see, you always start one node at a time, no node detects each other.  
> > They all use same address and port 10.26.180.190:9300. Starting and  
> > stopping one node after each other can't work. Check if you can set up a  
> > server node which stays active, and then connect with a client node, which  
> > can be recognized by using a different port than 9300 (it should be 9301  
> > since 9300 is allocated).
> > 
> > Jörg
> > 
> > On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:
> > 
> > > Hi, Jörg  
> > > I attached log file from the elasticsearch run.  
> > > Thanks,
> > > 
> > > On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:
> > > 
> > > > You are not giving us the full log trace with the error cause. Please  
> > > > switch your log level into DEBUG or TRACE mode, restart the ES node again,  
> > > > and try your client to connect. You will see the full error in the logs.
> > > > 
> > > > Possible reasons I can think of: network interface setup, ES network  
> > > > configuration, cluster name mismatch, zen discovery timeout
> > > > 
> > > > Best regards,
> > > > 
> > > > Jörg
> > > > 
> > > > On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> > > > 
> > > > > Hi David,  
> > > > > Actually the elasticsearch is running on the same machine where I'm  
> > > > > trying to run java.  
> > > > > The elasticsearch is only one node and it's a master node, so I guess  
> > > > > it's a data node.
> > > > > 
> > > > > Thanks.
> > > > > 
> > > > > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > > > > 
> > > > > > It seems that the other node you are trying to connect to is not up.
> > > > > > 
> > > > > > That’s the way I understand your stacktrace.
> > > > > > 
> > > > > > I think that when you use a client node, you must have a running data  
> > > > > > node elsewhere.
> > > > > > 
> > > > > > HTH
> > > > > > 
> > > > > > David
> > > > > > 
> > > > > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)]  
> > > > > > _De la part de_ slavag  
> > > > > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > > > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > > > > _Objet :_ Java client can't start a node
> > > > > > 
> > > > > > Hi,
> > > > > > 
> > > > > > Trying simple java client sample :
> > > > > > 
> > > > > > Node node = nodeBuilder().client(true).node();
> > > > > > 
> > > > > > Client client = node.client();
> > > > > > 
> > > > > > With clean elasticsearch 0.19.9, without any changes to configuration
> > > > > > 
> > > > > > In the past, it was working fine, but now I'm getting in the  
> > > > > > elasticsearch console :
> > > > > > 
> > > > > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom  
> > > > > > Boy] received ping response ping\_response{target [[Boom  
> > > > > > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > > > > > Boy][do472RNfRry9KY5Y-t1vaQ
> > > > > > 
> > > > > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no  
> > > > > > matching id [144]
> > > > > > 
> > > > > > and then in the java :
> > > > > > 
> > > > > > Exception in thread "main"  
> > > > > > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > > > > > 
> > > > > > ```
> > > > > > at java.lang.Thread.run(Thread.java:722)
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > Thanks.
> > > > > > 
> > > > > > --
> > > > > 
> > > > > --

--

---

<div class="post-metadata">

**Author:** ![Slava\_G](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@Slava\_G](https://discuss.elastic.co/u/Slava_G)\
**Post date:** [November 18, 2012, 9:39am UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/10 "2012-11-18T09:39:39Z")

</div>

Tried after turned windows firewall off - same behavior.

On Friday, November 16, 2012 7:39:49 PM UTC+2, David Pilato wrote:

> Just wondering if you have something weird with your firewall settings,  
> especially if you run it under windows.
> 
> Could you double-check that?
> 
> --  
> David 😉  
> Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> 
> Le 16 nov. 2012 à 18:35, slavag \<[sla...@gmail.com](mailto:sla...@gmail.com) \<javascript:\>\> a écrit :
> 
> Hi Jörg ,  
> The elasticsearch is running as data node (single instance on my computer)  
> and client it's a simple java app with one line of code.  
> Actually, I don't have any idea what I'm doing wrong as it should be very  
> simple, but I spent a week and didn't find any problem that could cause  
> this issue.  
> The elasticsearch seems to be started and now I don't see any stop  
> notification as what before, but my java app failed to connect to the  
> elasticsearch.
> 
> Thanks.
> 
> On Wednesday, November 14, 2012 10:26:49 AM UTC+2, Jörg Prante wrote:
> 
> > Hi,
> > 
> > there is something on your machine which stops your data node immediately  
> > after ist has been started.
> > 
> > [2012-11-12 15:40:13,733][INFO][node] [Corbo,  
> > Jared] {0.19.9}[11076]: starting ...  
> > [2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo,  
> > Jared] new\_master [Corbo,  
> > Jared][QJqeSKH0QVWuMIOJyAZFDQ][inet[/10.26.180.190:9300]], reason:  
> > zen-disco-join (elected\_as\_master)  
> > [2012-11-12 15:40:17,739][INFO][node] [Corbo,  
> > Jared] {0.19.9}[11076]: started  
> > [2012-11-12 15:40:17,776][INFO][node] [Corbo,  
> > Jared] {0.19.9}[11076]: stopping ...
> > 
> > Next, another node comes up, but this node seems to be a client node.
> > 
> > [2012-11-12 15:40:33,030][INFO][node] [Piper]  
> > {0.19.9}[8136]: starting ...  
> > [2012-11-12 15:40:36,302][INFO][cluster.service] [Piper]  
> > new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]],  
> > reason: zen-disco-join (elected\_as\_master)  
> > [2012-11-12 15:40:36,354][DEBUG][transport.netty] [Piper]  
> > connected to node  
> > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]  
> > [2012-11-12 15:40:36,469][INFO][node] [Piper]  
> > {0.19.9}[8136]: started
> > 
> > [2012-11-12 15:42:56,299][DEBUG][transport.netty] [Piper]  
> > disconnected from  
> > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]
> > 
> > You see, you always start one node at a time, no node detects each other.  
> > They all use same address and port 10.26.180.190:9300. Starting and  
> > stopping one node after each other can't work. Check if you can set up a  
> > server node which stays active, and then connect with a client node, which  
> > can be recognized by using a different port than 9300 (it should be 9301  
> > since 9300 is allocated).
> > 
> > Jörg
> > 
> > On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:
> > 
> > > Hi, Jörg  
> > > I attached log file from the elasticsearch run.  
> > > Thanks,
> > > 
> > > On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:
> > > 
> > > > You are not giving us the full log trace with the error cause. Please  
> > > > switch your log level into DEBUG or TRACE mode, restart the ES node again,  
> > > > and try your client to connect. You will see the full error in the logs.
> > > > 
> > > > Possible reasons I can think of: network interface setup, ES network  
> > > > configuration, cluster name mismatch, zen discovery timeout
> > > > 
> > > > Best regards,
> > > > 
> > > > Jörg
> > > > 
> > > > On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> > > > 
> > > > > Hi David,  
> > > > > Actually the elasticsearch is running on the same machine where I'm  
> > > > > trying to run java.  
> > > > > The elasticsearch is only one node and it's a master node, so I guess  
> > > > > it's a data node.
> > > > > 
> > > > > Thanks.
> > > > > 
> > > > > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > > > > 
> > > > > > It seems that the other node you are trying to connect to is not up.
> > > > > > 
> > > > > > That’s the way I understand your stacktrace.
> > > > > > 
> > > > > > I think that when you use a client node, you must have a running data  
> > > > > > node elsewhere.
> > > > > > 
> > > > > > HTH
> > > > > > 
> > > > > > David
> > > > > > 
> > > > > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)]  
> > > > > > _De la part de_ slavag  
> > > > > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > > > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > > > > _Objet :_ Java client can't start a node
> > > > > > 
> > > > > > Hi,
> > > > > > 
> > > > > > Trying simple java client sample :
> > > > > > 
> > > > > > Node node = nodeBuilder().client(true).node();
> > > > > > 
> > > > > > Client client = node.client();
> > > > > > 
> > > > > > With clean elasticsearch 0.19.9, without any changes to configuration
> > > > > > 
> > > > > > In the past, it was working fine, but now I'm getting in the  
> > > > > > elasticsearch console :
> > > > > > 
> > > > > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom  
> > > > > > Boy] received ping response ping\_response{target [[Boom  
> > > > > > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > > > > > Boy][do472RNfRry9KY5Y-t1vaQ
> > > > > > 
> > > > > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no  
> > > > > > matching id [144]
> > > > > > 
> > > > > > and then in the java :
> > > > > > 
> > > > > > Exception in thread "main"  
> > > > > > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > > > > > 
> > > > > > ```
> > > > > > at 
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > > > > > 
> > > > > > ```
> > > > > > at java.lang.Thread.run(Thread.java:722)
> > > > > > 
> > > > > > ```
> > > > > > 
> > > > > > Thanks.
> > > > > > 
> > > > > > --
> > > > > 
> > > > > --

--

---

<div class="post-metadata">

**Author:** ![Slava\_G](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@Slava\_G](https://discuss.elastic.co/u/Slava_G)\
**Post date:** [November 18, 2012, 9:40am UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/11 "2012-11-18T09:40:44Z")

</div>

No, computer doesn't changes it IP, same IP when started elasticsearch and  
the client.  
Thanks.

On Friday, November 16, 2012 9:38:31 PM UTC+2, Igor Motov wrote:

> How often does ip address of your machine changes? Could the following  
> scenario be your case: you start elasticsearch server, ip changes and then  
> start the client and it fails to connect?
> 
> On Friday, November 16, 2012 12:39:49 PM UTC-5, David Pilato wrote:
> 
> > Just wondering if you have something weird with your firewall settings,  
> > especially if you run it under windows.
> > 
> > Could you double-check that?
> > 
> > --  
> > David 😉  
> > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > 
> > Le 16 nov. 2012 à 18:35, slavag [sla...@gmail.com](mailto:sla...@gmail.com) a écrit :
> > 
> > Hi Jörg ,  
> > The elasticsearch is running as data node (single instance on my  
> > computer) and client it's a simple java app with one line of code.  
> > Actually, I don't have any idea what I'm doing wrong as it should be very  
> > simple, but I spent a week and didn't find any problem that could cause  
> > this issue.  
> > The elasticsearch seems to be started and now I don't see any stop  
> > notification as what before, but my java app failed to connect to the  
> > elasticsearch.
> > 
> > Thanks.
> > 
> > On Wednesday, November 14, 2012 10:26:49 AM UTC+2, Jörg Prante wrote:
> > 
> > > Hi,
> > > 
> > > there is something on your machine which stops your data node  
> > > immediately after ist has been started.
> > > 
> > > [2012-11-12 15:40:13,733][INFO][node] [Corbo,  
> > > Jared] {0.19.9}[11076]: starting ...  
> > > [2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo,  
> > > Jared] new\_master [Corbo,  
> > > Jared][QJqeSKH0QVWuMIOJyAZFDQ][inet[/10.26.180.190:9300]], reason:  
> > > zen-disco-join (elected\_as\_master)  
> > > [2012-11-12 15:40:17,739][INFO][node] [Corbo,  
> > > Jared] {0.19.9}[11076]: started  
> > > [2012-11-12 15:40:17,776][INFO][node] [Corbo,  
> > > Jared] {0.19.9}[11076]: stopping ...
> > > 
> > > Next, another node comes up, but this node seems to be a client node.
> > > 
> > > [2012-11-12 15:40:33,030][INFO][node] [Piper]  
> > > {0.19.9}[8136]: starting ...  
> > > [2012-11-12 15:40:36,302][INFO][cluster.service] [Piper]  
> > > new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]],  
> > > reason: zen-disco-join (elected\_as\_master)  
> > > [2012-11-12 15:40:36,354][DEBUG][transport.netty] [Piper]  
> > > connected to node  
> > > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]  
> > > [2012-11-12 15:40:36,469][INFO][node] [Piper]  
> > > {0.19.9}[8136]: started
> > > 
> > > [2012-11-12 15:42:56,299][DEBUG][transport.netty] [Piper]  
> > > disconnected from  
> > > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]
> > > 
> > > You see, you always start one node at a time, no node detects each  
> > > other. They all use same address and port 10.26.180.190:9300. Starting  
> > > and stopping one node after each other can't work. Check if you can set up  
> > > a server node which stays active, and then connect with a client node,  
> > > which can be recognized by using a different port than 9300 (it should be  
> > > 9301 since 9300 is allocated).
> > > 
> > > Jörg
> > > 
> > > On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:
> > > 
> > > > Hi, Jörg  
> > > > I attached log file from the elasticsearch run.  
> > > > Thanks,
> > > > 
> > > > On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:
> > > > 
> > > > > You are not giving us the full log trace with the error cause. Please  
> > > > > switch your log level into DEBUG or TRACE mode, restart the ES node again,  
> > > > > and try your client to connect. You will see the full error in the logs.
> > > > > 
> > > > > Possible reasons I can think of: network interface setup, ES network  
> > > > > configuration, cluster name mismatch, zen discovery timeout
> > > > > 
> > > > > Best regards,
> > > > > 
> > > > > Jörg
> > > > > 
> > > > > On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> > > > > 
> > > > > > Hi David,  
> > > > > > Actually the elasticsearch is running on the same machine where I'm  
> > > > > > trying to run java.  
> > > > > > The elasticsearch is only one node and it's a master node, so I guess  
> > > > > > it's a data node.
> > > > > > 
> > > > > > Thanks.
> > > > > > 
> > > > > > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > > > > > 
> > > > > > > It seems that the other node you are trying to connect to is not up.
> > > > > > > 
> > > > > > > That’s the way I understand your stacktrace.
> > > > > > > 
> > > > > > > I think that when you use a client node, you must have a running  
> > > > > > > data node elsewhere.
> > > > > > > 
> > > > > > > HTH
> > > > > > > 
> > > > > > > David
> > > > > > > 
> > > > > > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [[mailto:elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)]  
> > > > > > > _De la part de_ slavag  
> > > > > > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > > > > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > > > > > _Objet :_ Java client can't start a node
> > > > > > > 
> > > > > > > Hi,
> > > > > > > 
> > > > > > > Trying simple java client sample :
> > > > > > > 
> > > > > > > Node node = nodeBuilder().client(true).node();
> > > > > > > 
> > > > > > > Client client = node.client();
> > > > > > > 
> > > > > > > With clean elasticsearch 0.19.9, without any changes to configuration
> > > > > > > 
> > > > > > > In the past, it was working fine, but now I'm getting in the  
> > > > > > > elasticsearch console :
> > > > > > > 
> > > > > > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast] [Boom  
> > > > > > > Boy] received ping response ping\_response{target [[Boom  
> > > > > > > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > > > > > > Boy][do472RNfRry9KY5Y-t1vaQ
> > > > > > > 
> > > > > > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no  
> > > > > > > matching id [144]
> > > > > > > 
> > > > > > > and then in the java :
> > > > > > > 
> > > > > > > Exception in thread "main"  
> > > > > > > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > > > > > > 
> > > > > > > ```
> > > > > > > at 
> > > > > > > 
> > > > > > > ```
> > > > > > > 
> > > > > > > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > > > > > > 
> > > > > > > ```
> > > > > > > at 
> > > > > > > 
> > > > > > > ```
> > > > > > > 
> > > > > > > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > > > > > > 
> > > > > > > ```
> > > > > > > at 
> > > > > > > 
> > > > > > > ```
> > > > > > > 
> > > > > > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > > > > > > 
> > > > > > > ```
> > > > > > > at 
> > > > > > > 
> > > > > > > ```
> > > > > > > 
> > > > > > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > > > > > > 
> > > > > > > ```
> > > > > > > at java.lang.Thread.run(Thread.java:722)
> > > > > > > 
> > > > > > > ```
> > > > > > > 
> > > > > > > Thanks.
> > > > > > > 
> > > > > > > --
> > > > > > 
> > > > > > --

--

---

<div class="post-metadata">

**Author:** ![Igor\_Motov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igor_motov/32/45193_2.png) [@Igor\_Motov](https://discuss.elastic.co/u/Igor_Motov)\
**Post date:** [November 18, 2012, 12:51pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/12 "2012-11-18T12:51:19Z")

</div>

It does according to the log:

[2012-11-12 15:40:33,189][INFO][transport] [Piper]  
bound\_address {inet[/0.0.0.0:9300]}, publish\_address  
{inet[/10.26.180.190:9300]}  
[2012-11-12 15:57:33,499][INFO][transport] [Living  
Tribunal] bound\_address {inet[/0.0.0.0:9300]}, publish\_address  
{inet[/10.182.224.173:9300]}

On Sunday, November 18, 2012 4:40:44 AM UTC-5, slavag wrote:

> No, computer doesn't changes it IP, same IP when started elasticsearch and  
> the client.  
> Thanks.
> 
> On Friday, November 16, 2012 9:38:31 PM UTC+2, Igor Motov wrote:
> 
> > How often does ip address of your machine changes? Could the following  
> > scenario be your case: you start elasticsearch server, ip changes and then  
> > start the client and it fails to connect?
> > 
> > On Friday, November 16, 2012 12:39:49 PM UTC-5, David Pilato wrote:
> > 
> > > Just wondering if you have something weird with your firewall settings,  
> > > especially if you run it under windows.
> > > 
> > > Could you double-check that?
> > > 
> > > --  
> > > David 😉  
> > > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > > 
> > > Le 16 nov. 2012 à 18:35, slavag [sla...@gmail.com](mailto:sla...@gmail.com) a écrit :
> > > 
> > > Hi Jörg ,  
> > > The elasticsearch is running as data node (single instance on my  
> > > computer) and client it's a simple java app with one line of code.  
> > > Actually, I don't have any idea what I'm doing wrong as it should be  
> > > very simple, but I spent a week and didn't find any problem that could  
> > > cause this issue.  
> > > The elasticsearch seems to be started and now I don't see any stop  
> > > notification as what before, but my java app failed to connect to the  
> > > elasticsearch.
> > > 
> > > Thanks.
> > > 
> > > On Wednesday, November 14, 2012 10:26:49 AM UTC+2, Jörg Prante wrote:
> > > 
> > > > Hi,
> > > > 
> > > > there is something on your machine which stops your data node  
> > > > immediately after ist has been started.
> > > > 
> > > > [2012-11-12 15:40:13,733][INFO][node] [Corbo,  
> > > > Jared] {0.19.9}[11076]: starting ...  
> > > > [2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo,  
> > > > Jared] new\_master [Corbo,  
> > > > Jared][QJqeSKH0QVWuMIOJyAZFDQ][inet[/10.26.180.190:9300]], reason:  
> > > > zen-disco-join (elected\_as\_master)  
> > > > [2012-11-12 15:40:17,739][INFO][node] [Corbo,  
> > > > Jared] {0.19.9}[11076]: started  
> > > > [2012-11-12 15:40:17,776][INFO][node] [Corbo,  
> > > > Jared] {0.19.9}[11076]: stopping ...
> > > > 
> > > > Next, another node comes up, but this node seems to be a client node.
> > > > 
> > > > [2012-11-12 15:40:33,030][INFO][node] [Piper]  
> > > > {0.19.9}[8136]: starting ...  
> > > > [2012-11-12 15:40:36,302][INFO][cluster.service] [Piper]  
> > > > new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]],  
> > > > reason: zen-disco-join (elected\_as\_master)  
> > > > [2012-11-12 15:40:36,354][DEBUG][transport.netty] [Piper]  
> > > > connected to node  
> > > > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]  
> > > > [2012-11-12 15:40:36,469][INFO][node] [Piper]  
> > > > {0.19.9}[8136]: started
> > > > 
> > > > [2012-11-12 15:42:56,299][DEBUG][transport.netty] [Piper]  
> > > > disconnected from  
> > > > [[Piper][SYnQFrA\_RwSXoBX9Tc9-Rw][inet[/10.26.180.190:9300]]]
> > > > 
> > > > You see, you always start one node at a time, no node detects each  
> > > > other. They all use same address and port 10.26.180.190:9300. Starting  
> > > > and stopping one node after each other can't work. Check if you can set up  
> > > > a server node which stays active, and then connect with a client node,  
> > > > which can be recognized by using a different port than 9300 (it should be  
> > > > 9301 since 9300 is allocated).
> > > > 
> > > > Jörg
> > > > 
> > > > On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:
> > > > 
> > > > > Hi, Jörg  
> > > > > I attached log file from the elasticsearch run.  
> > > > > Thanks,
> > > > > 
> > > > > On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:
> > > > > 
> > > > > > You are not giving us the full log trace with the error cause. Please  
> > > > > > switch your log level into DEBUG or TRACE mode, restart the ES node again,  
> > > > > > and try your client to connect. You will see the full error in the logs.
> > > > > > 
> > > > > > Possible reasons I can think of: network interface setup, ES network  
> > > > > > configuration, cluster name mismatch, zen discovery timeout
> > > > > > 
> > > > > > Best regards,
> > > > > > 
> > > > > > Jörg
> > > > > > 
> > > > > > On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> > > > > > 
> > > > > > > Hi David,  
> > > > > > > Actually the elasticsearch is running on the same machine where I'm  
> > > > > > > trying to run java.  
> > > > > > > The elasticsearch is only one node and it's a master node, so I  
> > > > > > > guess it's a data node.
> > > > > > > 
> > > > > > > Thanks.
> > > > > > > 
> > > > > > > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > > > > > > 
> > > > > > > > It seems that the other node you are trying to connect to is not up.
> > > > > > > > 
> > > > > > > > That’s the way I understand your stacktrace.
> > > > > > > > 
> > > > > > > > I think that when you use a client node, you must have a running  
> > > > > > > > data node elsewhere.
> > > > > > > > 
> > > > > > > > HTH
> > > > > > > > 
> > > > > > > > David
> > > > > > > > 
> > > > > > > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [mailto:  
> > > > > > > > [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)] _De la part de_ slavag  
> > > > > > > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > > > > > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > > > > > > _Objet :_ Java client can't start a node
> > > > > > > > 
> > > > > > > > Hi,
> > > > > > > > 
> > > > > > > > Trying simple java client sample :
> > > > > > > > 
> > > > > > > > Node node = nodeBuilder().client(true).node();
> > > > > > > > 
> > > > > > > > Client client = node.client();
> > > > > > > > 
> > > > > > > > With clean elasticsearch 0.19.9, without any changes to  
> > > > > > > > configuration
> > > > > > > > 
> > > > > > > > In the past, it was working fine, but now I'm getting in the  
> > > > > > > > elasticsearch console :
> > > > > > > > 
> > > > > > > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.multicast]  
> > > > > > > > [Boom Boy] received ping response ping\_response{target [[Boom  
> > > > > > > > Boy][do472RNfRry9KY5Y-t1vaQ][inet[/10.0.0.10:9300]]], master [[Boom  
> > > > > > > > Boy][do472RNfRry9KY5Y-t1vaQ
> > > > > > > > 
> > > > > > > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no  
> > > > > > > > matching id [144]
> > > > > > > > 
> > > > > > > > and then in the java :
> > > > > > > > 
> > > > > > > > Exception in thread "main"  
> > > > > > > > org.elasticsearch.discovery.MasterNotDiscoveredException: waited for [30s]
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > at 
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > 
> > > > > > > > org.elasticsearch.action.support.master.TransportMasterNodeOperationAction$3.onTimeout(TransportMasterNodeOperationAction.java:169)
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > at 
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > 
> > > > > > > > org.elasticsearch.cluster.service.InternalClusterService$NotifyTimeout.run(InternalClusterService.java:356)
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > at 
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > 
> > > > > > > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > at 
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > 
> > > > > > > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > at java.lang.Thread.run(Thread.java:722)
> > > > > > > > 
> > > > > > > > ```
> > > > > > > > 
> > > > > > > > Thanks.
> > > > > > > > 
> > > > > > > > --
> > > > > > > 
> > > > > > > --

--

---

<div class="post-metadata">

**Author:** ![Slava\_G](https://avatars.discourse-cdn.com/v4/letter/s/e9c0ed/32.png) [@Slava\_G](https://discuss.elastic.co/u/Slava_G)\
**Post date:** [November 18, 2012, 6:33pm UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/13 "2012-11-18T18:33:59Z")

</div>

This happened, once I switched wifi network, but not automatically, only  
manual operation that I initiated. So, I can ensure that no network  
changed.  
On Nov 18, 2012 4:51 AM, "Igor Motov" [imotov@gmail.com](mailto:imotov@gmail.com) wrote:

> It does according to the log:
> 
> [2012-11-12 15:40:33,189][INFO][transport] [Piper]  
> bound\_address {inet[/0.0.0.0:9300]}, publish\_address {inet[/  
> 10.26.180.190:9300]}  
> [2012-11-12 15:57:33,499][INFO][transport] [Living  
> Tribunal] bound\_address {inet[/0.0.0.0:9300]}, publish\_address {inet[/  
> 10.182.224.173:9300]}
> 
> On Sunday, November 18, 2012 4:40:44 AM UTC-5, slavag wrote:
> 
> > No, computer doesn't changes it IP, same IP when started elasticsearch  
> > and the client.  
> > Thanks.
> > 
> > On Friday, November 16, 2012 9:38:31 PM UTC+2, Igor Motov wrote:
> > 
> > > How often does ip address of your machine changes? Could the following  
> > > scenario be your case: you start elasticsearch server, ip changes and then  
> > > start the client and it fails to connect?
> > > 
> > > On Friday, November 16, 2012 12:39:49 PM UTC-5, David Pilato wrote:
> > > 
> > > > Just wondering if you have something weird with your firewall settings,  
> > > > especially if you run it under windows.
> > > > 
> > > > Could you double-check that?
> > > > 
> > > > --  
> > > > David 😉  
> > > > Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs
> > > > 
> > > > Le 16 nov. 2012 à 18:35, slavag [sla...@gmail.com](mailto:sla...@gmail.com) a écrit :
> > > > 
> > > > Hi Jörg ,  
> > > > The elasticsearch is running as data node (single instance on my  
> > > > computer) and client it's a simple java app with one line of code.  
> > > > Actually, I don't have any idea what I'm doing wrong as it should be  
> > > > very simple, but I spent a week and didn't find any problem that could  
> > > > cause this issue.  
> > > > The elasticsearch seems to be started and now I don't see any stop  
> > > > notification as what before, but my java app failed to connect to the  
> > > > elasticsearch.
> > > > 
> > > > Thanks.
> > > > 
> > > > On Wednesday, November 14, 2012 10:26:49 AM UTC+2, Jörg Prante wrote:
> > > > 
> > > > > Hi,
> > > > > 
> > > > > there is something on your machine which stops your data node  
> > > > > immediately after ist has been started.
> > > > > 
> > > > > [2012-11-12 15:40:13,733][INFO][node] [Corbo,  
> > > > > Jared] {0.19.9}[11076]: starting ...  
> > > > > [2012-11-12 15:40:17,345][INFO][cluster.service] [Corbo,  
> > > > > Jared] new\_master [Corbo, Jared][QJqeSKH0QVWuMIOJyAZFDQ]\*\*  
> > > > > [inet[/10.26.180.190:9300]], reason: zen-disco-join  
> > > > > (elected\_as\_master)  
> > > > > [2012-11-12 15:40:17,739][INFO][node] [Corbo,  
> > > > > Jared] {0.19.9}[11076]: started  
> > > > > [2012-11-12 15:40:17,776][INFO][node] [Corbo,  
> > > > > Jared] {0.19.9}[11076]: stopping ...
> > > > > 
> > > > > Next, another node comes up, but this node seems to be a client node.
> > > > > 
> > > > > [2012-11-12 15:40:33,030][INFO][node] [Piper]  
> > > > > {0.19.9}[8136]: starting ...  
> > > > > [2012-11-12 15:40:36,302][INFO][cluster.service] [Piper]  
> > > > > new\_master [Piper][SYnQFrA\_RwSXoBX9Tc9-**Rw][inet[/10.26.180.190:9300  
> > > > > ]]**, reason: zen-disco-join (elected\_as\_master)  
> > > > > [2012-11-12 15:40:36,354][DEBUG][\*\*transport.netty] [Piper]  
> > > > > connected to node [[Piper][SYnQFrA\_RwSXoBX9Tc9-**Rw][inet[/  
> > > > > 10.26.180.190:9300]]**]  
> > > > > [2012-11-12 15:40:36,469][INFO][node] [Piper]  
> > > > > {0.19.9}[8136]: started
> > > > > 
> > > > > [2012-11-12 15:42:56,299][DEBUG][\*\*transport.netty] [Piper]  
> > > > > disconnected from [[Piper][SYnQFrA\_RwSXoBX9Tc9-**Rw][inet[/  
> > > > > 10.26.180.190:9300]]**]
> > > > > 
> > > > > You see, you always start one node at a time, no node detects each  
> > > > > other. They all use same address and port 10.26.180.190:9300.  
> > > > > Starting and stopping one node after each other can't work. Check if you  
> > > > > can set up a server node which stays active, and then connect with a client  
> > > > > node, which can be recognized by using a different port than 9300 (it  
> > > > > should be 9301 since 9300 is allocated).
> > > > > 
> > > > > Jörg
> > > > > 
> > > > > On Monday, November 12, 2012 9:37:07 PM UTC+1, slavag wrote:
> > > > > 
> > > > > > Hi, Jörg  
> > > > > > I attached log file from the elasticsearch run.  
> > > > > > Thanks,
> > > > > > 
> > > > > > On Monday, November 12, 2012 10:08:08 AM UTC+2, Jörg Prante wrote:
> > > > > > 
> > > > > > > You are not giving us the full log trace with the error cause.  
> > > > > > > Please switch your log level into DEBUG or TRACE mode, restart the ES node  
> > > > > > > again, and try your client to connect. You will see the full error in the  
> > > > > > > logs.
> > > > > > > 
> > > > > > > Possible reasons I can think of: network interface setup, ES network  
> > > > > > > configuration, cluster name mismatch, zen discovery timeout
> > > > > > > 
> > > > > > > Best regards,
> > > > > > > 
> > > > > > > Jörg
> > > > > > > 
> > > > > > > On Sunday, November 11, 2012 3:06:01 PM UTC+1, slavag wrote:
> > > > > > > 
> > > > > > > > Hi David,  
> > > > > > > > Actually the elasticsearch is running on the same machine where I'm  
> > > > > > > > trying to run java.  
> > > > > > > > The elasticsearch is only one node and it's a master node, so I  
> > > > > > > > guess it's a data node.
> > > > > > > > 
> > > > > > > > Thanks.
> > > > > > > > 
> > > > > > > > On Sunday, November 11, 2012 3:52:37 PM UTC+2, David Pilato wrote:
> > > > > > > > 
> > > > > > > > > It seems that the other node you are trying to connect to is not  
> > > > > > > > > up.
> > > > > > > > > 
> > > > > > > > > That’s the way I understand your stacktrace.
> > > > > > > > > 
> > > > > > > > > I think that when you use a client node, you must have a running  
> > > > > > > > > data node elsewhere.
> > > > > > > > > 
> > > > > > > > > HTH
> > > > > > > > > 
> > > > > > > > > David
> > > > > > > > > 
> > > > > > > > > _De :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com) [mailto:elasti...@\*\*  
> > > > > > > > > [googlegroups.com](http://googlegroups.com)] _De la part de_ slavag  
> > > > > > > > > _Envoyé :_ samedi 10 novembre 2012 23:29  
> > > > > > > > > _À :_ [elasti...@googlegroups.com](mailto:elasti...@googlegroups.com)  
> > > > > > > > > _Objet :_ Java client can't start a node
> > > > > > > > > 
> > > > > > > > > Hi,
> > > > > > > > > 
> > > > > > > > > Trying simple java client sample :
> > > > > > > > > 
> > > > > > > > > Node node = nodeBuilder().client(true).\*\*node();
> > > > > > > > > 
> > > > > > > > > Client client = node.client();
> > > > > > > > > 
> > > > > > > > > With clean elasticsearch 0.19.9, without any changes to  
> > > > > > > > > configuration
> > > > > > > > > 
> > > > > > > > > In the past, it was working fine, but now I'm getting in the  
> > > > > > > > > elasticsearch console :
> > > > > > > > > 
> > > > > > > > > [2012-11-11 00:15:41,416][WARN][discovery.zen.ping.\*\*multicast]  
> > > > > > > > > [Boom Boy] received ping response ping\_response{target [[Boom  
> > > > > > > > > Boy][do472RNfRry9KY5Y-t1vaQ][\*\*inet[/10.0.0.10:9300]]], master  
> > > > > > > > > [[Boom Boy][do472RNfRry9KY5Y-t1vaQ
> > > > > > > > > 
> > > > > > > > > ][inet[/10.0.0.10:9300]]], cluster\_name[elasticsearch]} with no  
> > > > > > > > > matching id [144]
> > > > > > > > > 
> > > > > > > > > and then in the java :
> > > > > > > > > 
> > > > > > > > > Exception in thread "main" org.elasticsearch.discovery.\*\*MasterNotDiscoveredException:  
> > > > > > > > > waited for [30s]
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > at org.elasticsearch.action. **support.master.**
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > 
> > > > > > > > > TransportMasterNodeOperationAc**tion$3.onTimeout(**  
> > > > > > > > > TransportMasterNodeOperationAc\*\*tion.java:169)
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > at org.elasticsearch.cluster. **service.**
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > 
> > > > > > > > > InternalClusterService$**NotifyTimeout.run(**  
> > > > > > > > > InternalClusterService.java:\*\*356)
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > at java.util.concurrent.**ThreadPoolExecutor.runWorker(*
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > 
> > > > > > > > > \*ThreadPoolExecutor.java:1110)
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > at java.util.concurrent.**ThreadPoolExecutor$Worker.run(
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > 
> > > > > > > > > \*\*ThreadPoolExecutor.java:603)
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > at java.lang.Thread.run(Thread.**java:722)
> > > > > > > > > 
> > > > > > > > > ```
> > > > > > > > > 
> > > > > > > > > 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:03am UTC](https://discuss.elastic.co/t/java-client-cant-start-a-node/9661/14 "2017-07-06T03:03:48Z")

</div>


