Problem binding elasticsearch to host interface

Hi,
I recently downloaded 5.0 and started to play with the configuration. I have few hosts on the network with logstash configured to forward messages to my elasticsearch, in the earlier version I configured it to listen on loopback as well as main (eth0) interface. The same configuration on 5.0 seems to be failing.

Tried these entries and none of them worked so far ..

network.host: _site_
or
network.host: _global_
or
network.host: _global:ipv4_
or
network.host: ["10.65.0.12","127.0.0.1"]
or
network.host: 10.65.0.12, 127.0.0.1

-- In almost all cases, it seems to fail with the following error
[2016-11-01T00:45:15,627][INFO ][o.e.b.BootstrapCheck ] [8siMmPg] bound or publishing to a non-loopback or non-link-local address, enforcing bootstrap checks
[2016-11-01T00:45:15,629][ERROR][o.e.b.Bootstrap ] [8siMmPg] node validation exception
bootstrap checks failed

-- when I specify global
[2016-11-01T00:57:48,486][ERROR][o.e.b.Bootstrap ] [8siMmPg] Exception
java.lang.IllegalArgumentException: No up-and-running global-scope (public) addresses found, got [name:lo (lo), name:eth0 (eth0)]
at org.elasticsearch.common.network.NetworkUtils.getGlobalAddresses(NetworkUtils.java:207) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.common.network.NetworkService.resolveInternal(NetworkService.java:254) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.common.network.NetworkService.resolveInetAddresses(NetworkService.java:220) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.common.network.NetworkService.resolveBindHostAddresses(NetworkService.java:130) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.transport.TcpTransport.bindServer(TcpTransport.java:575) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.transport.netty4.Netty4Transport.doStart(Netty4Transport.java:182) ~[?:?]
at org.elasticsearch.common.component.AbstractLifecycleComponent.start(AbstractLifecycleComponent.java:68) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.transport.TransportService.doStart(TransportService.java:182) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.common.component.AbstractLifecycleComponent.start(AbstractLifecycleComponent.java:68) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.node.Node.start(Node.java:525) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Bootstrap.start(Bootstrap.java:211) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:288) [elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:112) [elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:103) [elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.cli.SettingCommand.execute(SettingCommand.java:54) [elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:96) [elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.cli.Command.main(Command.java:62) [elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:80) [elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:73) [elasticsearch-5.0.0.jar:5.0.0]
[2016-11-01T00:57:48,492][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: java.lang.IllegalArgumentException: No up-and-running global-scope (public) addresses found, got [name:lo (lo), name:eth0 (eth0)]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:116) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:103) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.cli.SettingCommand.execute(SettingCommand.java:54) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:96) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.cli.Command.main(Command.java:62) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:80) ~[elasticsearch-5.0.0.jar:5.0.0]
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:73) ~[elasticsearch-5.0.0.jar:5.0.0]
Caused by: java.lang.IllegalArgumentException: No up-and-running global-scope (public) addresses found, got [name:lo (lo), name:eth0 (eth0)]

1 Like

When you get:

[2016-11-01T00:45:15,629][ERROR][o.e.b.Bootstrap ] [8siMmPg] node validation exception bootstrap checks failed

You need to fix all the stuff which is described in the stacktrace.

Thanks David. Any pointers what the ERROR is implying ? I'm fairly new to the stack and this is a fresh install and I have not made any customization to the configuration yet - except that I would like take feed from an external source. For now, ES is up and running on loopback interface and I have a work-around -- using iptables (port forwarding). I surely would like to fix it and get ridoff the kluge.

I can't without seeing the logs.