# Indices having filter with required.\_id = NODE\_ID blocking replica shard to allocate

**URL:** <https://discuss.elastic.co/t/indices-having-filter-with-required-id-node-id-blocking-replica-shard-to-allocate/225641>\
**Category:** Elasticsearch\
**Created:** [March 30, 2020, 9:29am UTC](https://discuss.elastic.co/t/indices-having-filter-with-required-id-node-id-blocking-replica-shard-to-allocate/225641 "2020-03-30T09:29:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![oneoneonepig](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/oneoneonepig/32/66018_2.png) [@oneoneonepig](https://discuss.elastic.co/u/oneoneonepig)\
**Post date:** [March 30, 2020, 9:29am UTC](https://discuss.elastic.co/t/indices-having-filter-with-required-id-node-id-blocking-replica-shard-to-allocate/225641/1 "2020-03-30T09:29:24Z")

</div>

My indices are having 1 replicas and 3 shards (3x2)

There are some indices having a filter `"index.routing.allocation.required._id": id-of-a-certain-node`, blocking the replica shard to allocate on any node due to two restrictions:

1. (Decider: filter) Routing filters required the shards be allocated on a specific node
2. (Decider: same\_shard) Primary and replica shards cannot be on the same node

The routing filters are not applied by human, not sure why these filters exists.

There are also some shards un-allocated due to memory issue, but resolved after increasing memory and JVM heap.

The incidence is resolved, so I won't be able to provide additional error logs, but I'll try my best to answer any question regarding the issue.

Commands used for checking the status:

```auto
/_cat/health
/_cat/shards
/_cat/shards/<shard>
/<index>" | jq '."<index>".settings.index.routing'
/_cluster/allocation/explain

```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [April 27, 2020, 9:29am UTC](https://discuss.elastic.co/t/indices-having-filter-with-required-id-node-id-blocking-replica-shard-to-allocate/225641/2 "2020-04-27T09:29:27Z")

</div>

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