Elasticsearch ZEN_DISCOVERY_ SETTINGS_NOT_USED

Elasticsearch ZEN_DISCOVERY_ SETTINGS_NOT_USED

Opster Team

Nov 2020


In addition to reading this guide, run the Elasticsearch Health Check-Up. Detect problems and improve performance by analyzing your shard sizes, threadpools, memory, snapshots, disk watermarks and many more.
Free tool that requires no installation with +1000 users.

Run the Elasticsearch check-up to receive recommendations like this:

checklist Run Check-Up
error

The following configuration error was detected on node 123...

error-img

Description

This error can have a severe impact on your system. It's important to understand that it was caused by...

error-img

Recommendation

In order to resolve this issue and prevent it from occurring again, we recommend that you begin by changing the configuration to...

1

X-PUT curl -H "Content-Type: application/json" [customized recommendation]

Elasticsearch Zen Discovery Settings

What does it mean?

Zen discovery settings for cluster formation were deprecated in Elasticsearch version 7. If these settings are included in elasticsearch.yml files for version 7 and above, they should be removed to avoid confusion.

Reason for the changes:

Up until version 6 it was possible, using zen discovery mechanism, to inadvertently set unsafe settings which could result in a cluster becoming separated into two separate clusters (the split brain problem). The changes introduced in version 7 make a more robust configuration under which you will be warned (and the cluster will not start) if you set certain unsafe configurations. In particular, in the event of loss of master nodes for version 6 and earlier, you would be allowed to simply add new master nodes, with no guarantee that you had actually preserved the original cluster state, leading to the possibility of data loss.  

How to fix it:

Edit the elasticsearch.yml file in each node where you see the ZEN_DISCOVERY_SETTINGS_NOT_USED warning.  

The settings below have changed names:

discovery.zen.ping.unicast.hostsdiscovery.seed_hosts
discovery.zen.hosts_providerdiscovery.seed_providers
discovery.zen.no_master_blockcluster.no_master_block

Any other settings that start with:

discovery.zen

Can be removed.

You must restart the node for the change to take effect.  Remember to wait for your node to come back up and rejoin the cluster before restarting the next node. To check this, run:

GET _cluster/health

You should only restart nodes once the cluster is GREEN.

Run the Elasticsearch check-up to receive recommendations like this:

checklist Run Check-Up
error

The following configuration error was detected on node 123...

error-img

Description

This error can have a severe impact on your system. It's important to understand that it was caused by...

error-img

Recommendation

In order to resolve this issue and prevent it from occurring again, we recommend that you begin by changing the configuration to...

1

X-PUT curl -H "Content-Type: application/json" [customized recommendation]





Improve Elasticsearch Performance

Run The Analysis