Replicas remains unassigned

Hi I am currently in 6.4.2 version and I have lot of replica shards in "unassigned" state.

Below is the result That I get when I run query

GET /_cluster/allocation/explain
{
  "index": "log-2019.01.29",
  "shard": 0,
  "primary": false
}

"index": "log-2019.01.29",
  "shard": 0,
  "primary": false,
  "current_state": "unassigned",
  "unassigned_info": {
"reason": "ALLOCATION_FAILED",
"at": "2019-02-05T17:27:34.293Z",
"failed_allocation_attempts": 5,
"details": "failed shard on node [nusIaGG7SRWtv0Dw50KtiQ]: failed to update mapping for index, failure MapperParsingException[Failed to parse mapping [doc]: Root mapping definition has unsupported parameters:  [_size : {enabled=true}]]; nested: MapperParsingException[Root mapping definition has unsupported parameters:  [_size : {enabled=true}]]; ",
"last_allocation_status": "no_attempt"
  },
  "can_allocate": "no",
  "allocate_explanation": "cannot allocate because allocation is not permitted to any of the nodes"

I have already tried the POST /_cluster/reroute?retry_failed but still the same result

Below is the template that I have in logstash

{
    "template": "log",
    "index_patterns": ["log*"],
    "settings" : {
        "number_of_shards" : 5
    },
    "mappings":{
      "doc":{
         "_size": {
            "enabled": true
         }
      }
    }
}

PS: I have mapper size plugin enabled on all the nodes and this exception on only replicas seems confusing

Thank you

1 Like

This was my caused by my mistake. The mapper size plugin was not installed on all the Elasticsearch nodes.
Once this was corrected the replicas started getting assigned.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.