Unexpected value for setting it should be dash delimited – How to solve this Elasticsearch error

Opster Team

Aug-23, Version: 1.3-1.3

Before you dig into reading this guide, have you tried asking OpsGPT what this log means? You’ll receive a customized analysis of your log.

Try OpsGPT now for step-by-step guidance and tailored insights into your Elasticsearch operation.

Briefly, this error occurs when the Elasticsearch setting value is not dash-delimited as expected. Elasticsearch uses dash-delimited settings for better readability and organization. If a setting is not dash-delimited, it may cause confusion or errors. To resolve this issue, you should review your Elasticsearch settings and ensure that they are correctly dash-delimited. For example, if you have a setting like “index.number_of_shards”, it should be written as “index-number-of-shards”. Also, ensure that there are no spaces before or after the dashes.

For a complete solution to your to your search operation, try for free AutoOps for Elasticsearch & OpenSearch . With AutoOps and Opster’s proactive support, you don’t have to worry about your search operation – we take charge of it. Get improved performance & stability with less hardware.

This guide will help you check for common problems that cause the log ” Unexpected value [{}] for setting [{}]; it should be dash delimited ” to appear. To understand the issues related to this log, read the explanation below about the following Elasticsearch concepts: cluster, metadata and settings.

Log Context

Log “Unexpected value [{}] for setting [{}]; it should be dash delimited” classname is MetaDataUpdateSettingsService.java.
We extracted the following from Elasticsearch source code for those seeking an in-depth context :

final int min;
                    final int max;

                    final int dash = autoExpandReplicas.indexOf('-');
                    if (-1 == dash) {
                        logger.warn("Unexpected value [{}] for setting [{}]; it should be dash delimited";
                                autoExpandReplicas; IndexMetaData.SETTING_AUTO_EXPAND_REPLICAS);
                        continue;
                    }
                    final String sMin = autoExpandReplicas.substring(0; dash);
                    try {

 

How helpful was this guide?

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?