Problems with access to Elasticsearch form outside machine


(Alejandro Bartolomeo) #1

Hi all, I have problems to configure access to elasticsearch 7 from other machine. I made the same changes like elasticsearch 6.5 (and worked perfect) to access from outside but when I uncomment the "network.host: 0.0.0.0" the process try to start and in a few seconds going down. I attach the log:

[2019-03-15T01:56:48,167][INFO ][o.e.t.TransportService ] [node-1] publish_address {192.168.32.136:9300}, bound_addresses {[::]:9300}
[2019-03-15T01:56:48,183][INFO ][o.e.b.BootstrapChecks ] [node-1] bound or publishing to a non-loopback address, enforcing bootstrap checks
[2019-03-15T01:56:48,246][ERROR][o.e.b.Bootstrap ] [node-1] node validation exception
[1] bootstrap checks failed
[1]: the default discovery settings are unsuitable for production use; at least one of [discovery.seed_hosts, discovery.seed_providers, cluster.initial_master_nodes] must be configured
[2019-03-15T01:56:48,253][INFO ][o.e.n.Node ] [node-1] stopping ...
[2019-03-15T01:56:48,270][INFO ][o.e.n.Node ] [node-1] stopped
[2019-03-15T01:56:48,271][INFO ][o.e.n.Node ] [node-1] closing ...
[2019-03-15T01:56:48,299][INFO ][o.e.n.Node ] [node-1] closed
[2019-03-15T01:56:48,300][INFO ][o.e.x.m.p.NativeController] [node-1] Native controller process has stopped - no new native processes can be started


(Tim Vernum) #2

You are failing on bootstrap checks:

[2019-03-15T01:56:48,246][ERROR][o.e.b.Bootstrap ] [node-1] node validation exception
[1] bootstrap checks failed
[1]: the default discovery settings are unsuitable for production use; at least one of [discovery.seed_hosts, discovery.seed_providers, cluster.initial_master_nodes] must be configured

The cluster coordination algorithm has changed in 7.0 and in order to be safe it requires some specific configuration. We relax that requirement (that is, we run in a less-safe mode) when you bind to localhost only, but if/when you change network.host we enforce that your configure the cluster safely.

This is covered in the breaking changes documentation for 7.0


(Alejandro Bartolomeo) #3

Thanks Tim, I built a test machine with this new version. But to test same interesting new features, I need some cookbook to resolve this config.


(David Turner) #4

The resolution is in the error message:

In this case, I think it's enough to set cluster.initial_master_nodes: node-1.