# Network.host or http.host - documentation problem?

**URL:** https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179
**Category:** Elasticsearch
**Created:** [October 27, 2016, 6:25pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179 "2016-10-27T18:25:11Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![tsmori](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsmori/32/47626_2.png) [@tsmori](https://discuss.elastic.co/u/tsmori)
#### Post date: [October 27, 2016, 6:25pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/1 "2016-10-27T18:25:11Z")

</div>

The default works fine, however it's only binding to localhost. I want to be able to bind elasticsearch to a non-loopback IP. Docs say this is possible, but setting 0.0.0.0 or the actual adapater IP results in the following:

[2016-10-27T14:16:13,023][INFO][o.e.b.BootstrapCheck] [ssosearch01] bound or publishing to a non-loopback or non-link-local address, enforcing bootstrap checks  
[2016-10-27T14:16:13,024][ERROR][o.e.b.Bootstrap] [ssosearch01] node validation exception  
bootstrap checks failed

The only other thing I've set it to that works is ::1, but that doesn't help either. I need a remote apache server to be able to proxy to it.

What I just did that worked was to change network.host to http.host. The docs says the setting is network.host and that's how it's set up for the other 2 nodes I installed.

---

<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: [October 27, 2016, 7:50pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/2 "2016-10-27T19:50:39Z")

</div>

The rest of the trace is super important. What is it?

---

<div class="post-metadata">

### Author: ![tsmori](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsmori/32/47626_2.png) [@tsmori](https://discuss.elastic.co/u/tsmori)
#### Post date: [October 27, 2016, 7:58pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/3 "2016-10-27T19:58:12Z")

</div>

This is the full block from the log. It didn't generate any java errors. This is using network.host = "0.0.0.0" in the elasticsearch.yml file. Note that I blanked out my local IP address, but it did pick it up correctly.

[2016-10-27T15:56:14,581][INFO][o.e.n.Node] [ssosearch03] initializing ...  
[2016-10-27T15:56:14,653][INFO][o.e.e.NodeEnvironment] [ssosearch03] using [1] data paths, mounts [[/sso (/dev/mapper/vg\_sas-lv\_sso)]], net usable\_space [79.9gb], net total\_space [79.9gb], spins? [possibly], types [xfs]  
[2016-10-27T15:56:14,653][INFO][o.e.e.NodeEnvironment] [ssosearch03] heap size [15.9gb], compressed ordinary object pointers [true]  
[2016-10-27T15:56:14,656][INFO][o.e.n.Node] [ssosearch03] version[5.0.0], pid[610], build[253032b/2016-10-26T04:37:51.531Z], OS[Linux/3.10.0-327.4.4.el7.x86\_64/amd64], JVM[Oracle Corporation/OpenJDK 64-Bit Server VM/1.8.0\_65/25.65-b01]  
[2016-10-27T15:56:15,359][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [aggs-matrix-stats]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [ingest-common]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [lang-expression]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [lang-groovy]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [lang-mustache]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [lang-painless]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [percolator]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [reindex]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [transport-netty3]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] loaded module [transport-netty4]  
[2016-10-27T15:56:15,360][INFO][o.e.p.PluginsService] [ssosearch03] no plugins loaded  
[2016-10-27T15:56:17,010][INFO][o.e.n.Node] [ssosearch03] initialized  
[2016-10-27T15:56:17,010][INFO][o.e.n.Node] [ssosearch03] starting ...  
[2016-10-27T15:56:17,137][INFO][o.e.t.TransportService] [ssosearch03] publish\_address {[my local IP address]:9300}, bound\_addresses {[::]:9300}  
[2016-10-27T15:56:17,142][INFO][o.e.b.BootstrapCheck] [ssosearch03] bound or publishing to a non-loopback or non-link-local address, enforcing bootstrap checks  
[2016-10-27T15:56:17,143][ERROR][o.e.b.Bootstrap] [ssosearch03] node validation exception  
bootstrap checks failed  
initial heap size [4294967296] not equal to maximum heap size [17179869184]; this can cause resize pauses and prevents mlockall from locking the entire heap  
[2016-10-27T15:56:17,145][INFO][o.e.n.Node] [ssosearch03] stopping ...  
[2016-10-27T15:56:17,156][INFO][o.e.n.Node] [ssosearch03] stopped  
[2016-10-27T15:56:17,156][INFO][o.e.n.Node] [ssosearch03] closing ...  
[2016-10-27T15:56:17,166][INFO][o.e.n.Node] [ssosearch03] closed

---

<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: [October 27, 2016, 8:36pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/4 "2016-10-27T20:36:29Z")

</div>

Fix the heap size then.

---

<div class="post-metadata">

### Author: ![tsmori](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsmori/32/47626_2.png) [@tsmori](https://discuss.elastic.co/u/tsmori)
#### Post date: [October 27, 2016, 8:54pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/5 "2016-10-27T20:54:32Z")

</div>

Okay, that did work although I could have sworn I had this issue before I made any jvm changes.

Still, this isn't a "best practices" issue if the service fails to start, it's a requirement that they match. The jvm.options file says "you should" set to the same value.

Also kinda interesting that I can change network.host to http.host and it ignores this requirement.

---

<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: [October 28, 2016, 12:03am UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/6 "2016-10-28T00:03:12Z")

</div>

> [@tsmori](#):
>
> The jvm.options file says "you should" set to the same value.

Please feel free to raise an issue so we can get that updated.

---

<div class="post-metadata">

### Author: ![opendoc42](https://avatars.discourse-cdn.com/v4/letter/o/7ab992/32.png) [@opendoc42](https://discuss.elastic.co/u/opendoc42)
#### Post date: [October 28, 2016, 5:29am UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/7 "2016-10-28T05:29:33Z")

</div>

Hi Tim,

I personally do not use the "network.host =" option. However I use:

```
network.bind_host: 0.0.0.0
network.publish_host: xxx.xxx.xxx.xxx

```

ES can listen on the loopback, and ES can work with LVS.

Alex.

---

<div class="post-metadata">

### Author: ![vmcleitao](https://avatars.discourse-cdn.com/v4/letter/v/f475e1/32.png) [@vmcleitao](https://discuss.elastic.co/u/vmcleitao)
#### Post date: [November 4, 2016, 12:19pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/8 "2016-11-04T12:19:10Z")

</div>

Hi,

I tried your solution but didn't work, the problem remains

[root@uh0088 ~]# tail -f /var/log/elasticsearch/elasticsearch.log  
[2016-11-04T12:13:24,957][INFO][o.e.n.Node] [ELK#1] starting ...  
[2016-11-04T12:13:25,164][INFO][o.e.t.TransportService] [ELK#1] publish\_address {10.50.131.44:9300}, bound\_addresses {[::]:9300}  
[2016-11-04T12:13:25,170][INFO][o.e.b.BootstrapCheck] [ELK#1] bound or publishing to a non-loopback or non-link-local address, enforcing bootstrap checks  
[2016-11-04T12:13:25,172][ERROR][o.e.b.Bootstrap] [ELK#1] node validation exception  
bootstrap checks failed  
max number of threads [1024] for user [elasticsearch] likely too low, increase to at least [2048]  
[2016-11-04T12:13:25,341][INFO][o.e.n.Node] [ELK#1] stopping ...  
[2016-11-04T12:13:25,414][INFO][o.e.n.Node] [ELK#1] stopped  
[2016-11-04T12:13:25,415][INFO][o.e.n.Node] [ELK#1] closing ...  
[2016-11-04T12:13:25,431][INFO][o.e.n.Node] [ELK#1] closed

#network.host:

# 

network.bind\_host: 0.0.0.0

# 

network.publish\_host: 10.50.131.44

---

<div class="post-metadata">

### Author: ![opendoc42](https://avatars.discourse-cdn.com/v4/letter/o/7ab992/32.png) [@opendoc42](https://discuss.elastic.co/u/opendoc42)
#### Post date: [November 4, 2016, 1:00pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/9 "2016-11-04T13:00:09Z")

</div>

Hello,

do you use debian ? You can disable IPV6

```
echo "net.ipv6.conf.all.disable_ipv6=1" > /etc/sysctl.d/disableipv6.conf 
reboot

```

Can you tell me if it works ?

---

<div class="post-metadata">

### Author: ![vmcleitao](https://avatars.discourse-cdn.com/v4/letter/v/f475e1/32.png) [@vmcleitao](https://discuss.elastic.co/u/vmcleitao)
#### Post date: [November 4, 2016, 1:23pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/10 "2016-11-04T13:23:17Z")

</div>

Hello,

I am using CentOS release 6.8 (Final).

Why did you refer IPv6 in this issue?

---

<div class="post-metadata">

### Author: ![opendoc42](https://avatars.discourse-cdn.com/v4/letter/o/7ab992/32.png) [@opendoc42](https://discuss.elastic.co/u/opendoc42)
#### Post date: [November 4, 2016, 2:36pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/11 "2016-11-04T14:36:05Z")

</div>

In your error message

```
[2016-11-04T12:13:25,164][INFO][o.e.t.TransportService] [ELK#1] publish_address {10.50.131.44:9300}, bound_addresses {[::]:9300}

```

I think ::1/128 is the IP loop back in ipv6

---

<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: [November 4, 2016, 4:21pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/12 "2016-11-04T16:21:30Z")

</div>

> [@vmcleitao](#):
>
> bootstrap checks failed  
> max number of threads [1024] for user [elasticsearch] likely too low, increase to at least [2048]

This ^

---

<div class="post-metadata">

### Author: ![laoyang360](https://avatars.discourse-cdn.com/v4/letter/l/a9a28c/32.png) [@laoyang360](https://discuss.elastic.co/u/laoyang360)
#### Post date: [January 10, 2017, 6:39am UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/13 "2017-01-10T06:39:05Z")

</div>

I have the same problem like you refer above. How to fix it ?

---

<div class="post-metadata">

### Author: ![tarun\_kayasth](https://avatars.discourse-cdn.com/v4/letter/t/a6a055/32.png) [@tarun\_kayasth](https://discuss.elastic.co/u/tarun_kayasth)
#### Post date: [February 9, 2017, 7:12pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/14 "2017-02-09T19:12:26Z")

</div>

I was able to fix the error using below properties but i am still facing issue clustering 2 nodes.  
on node 1:  
http.bind\_host: my-elasticnode-01  
http.publish\_host: my-elasticnode-01

on node 2:  
http.bind\_host: my-elasticnode-02  
http.publish\_host: my-elasticnode-02

---

<div class="post-metadata">

### Author: ![Neuron\_Ring](https://avatars.discourse-cdn.com/v4/letter/n/6a8cbe/32.png) [@Neuron\_Ring](https://discuss.elastic.co/u/Neuron_Ring)
#### Post date: [March 1, 2017, 5:28pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/15 "2017-03-01T17:28:02Z")

</div>

@tarun_kayasth I have the same issue.. Still got no clue at all. Tried several different settings. Did you get any luck on making it work ?  
If you can share the correct settings, that would be of great help..

---

<div class="post-metadata">

### Author: ![tsmori](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tsmori/32/47626_2.png) [@tsmori](https://discuss.elastic.co/u/tsmori)
#### Post date: [March 1, 2017, 8:27pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/16 "2017-03-01T20:27:17Z")

</div>

Yep, actually in my original case, it was due to the bootstrap check failure. Even though the config has separate entries for initial and max heap size, it actually requires you to set those to be exactly the same, otherwise the check fails and the service doesn't start.

I think I got it to skip past the error by using a different config directive, but this heap sizing mismatch was actually the problem.

---

<div class="post-metadata">

### Author: ![Neuron\_Ring](https://avatars.discourse-cdn.com/v4/letter/n/6a8cbe/32.png) [@Neuron\_Ring](https://discuss.elastic.co/u/Neuron_Ring)
#### Post date: [March 1, 2017, 8:43pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/17 "2017-03-01T20:43:41Z")

</div>

@tsmori Are you still able to run ES in a cluster ?  
In my jvm.options file. they are set to same value

```
# Xms represents the initial size of total heap space
# Xmx represents the maximum size of total heap space

-Xms2g
-Xmx2g
```

---

<div class="post-metadata">

### Author: ![Gokhan\_Sahin](https://avatars.discourse-cdn.com/v4/letter/g/e495f1/32.png) [@Gokhan\_Sahin](https://discuss.elastic.co/u/Gokhan_Sahin)
#### Post date: [March 2, 2017, 7:50am UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/18 "2017-03-02T07:50:00Z")

</div>

Hi  
Solution: elasticsearch.yml in file  
[cluster.name](http://cluster.name): my-application  
[node.name](http://node.name): ${hostname}  
node.master: true  
node.data: true  
transport.host: localhost  
transport.tcp.port: 9300  
network.host: 0.0.0.0  
http.port: 9200  
discovery.zen.minimum\_master\_nodes: 3

---

<div class="post-metadata">

### Author: ![Christian\_Javellana](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_javellana/32/16325_2.png) [@Christian\_Javellana](https://discuss.elastic.co/u/Christian_Javellana)
#### Post date: [March 14, 2017, 2:39pm UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/19 "2017-03-14T14:39:16Z")

</div>

Isn't setting transport.host to localhost disables clustering support as other nodes would not be able to talk to each other?

---

<div class="post-metadata">

### Author: ![yun](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yun/32/16634_2.png) [@yun](https://discuss.elastic.co/u/yun)
#### Post date: [March 23, 2017, 8:09am UTC](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179/20 "2017-03-23T08:09:36Z")

</div>

Thank you. I solved my problem.

[Next page](https://discuss.elastic.co/t/network-host-or-http-host-documentation-problem/64179.md?page=2)
