# Any efficient way to perform shards reduction of the original index? Need to do shards rebalancing after shards reduction?

**URL:** https://discuss.elastic.co/t/any-efficient-way-to-perform-shards-reduction-of-the-original-index-need-to-do-shards-rebalancing-after-shards-reduction/266574
**Category:** Elasticsearch
**Created:** [March 8, 2021, 3:08pm UTC](https://discuss.elastic.co/t/any-efficient-way-to-perform-shards-reduction-of-the-original-index-need-to-do-shards-rebalancing-after-shards-reduction/266574 "2021-03-08T15:08:33Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![qub123](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/qub123/32/55327_2.png) [@qub123](https://discuss.elastic.co/u/qub123)
#### Post date: [March 8, 2021, 3:08pm UTC](https://discuss.elastic.co/t/any-efficient-way-to-perform-shards-reduction-of-the-original-index-need-to-do-shards-rebalancing-after-shards-reduction/266574/1 "2021-03-08T15:08:33Z")

</div>

Hi, we are trying to reduce number of primary shards, from 5 shards and one replica shard of each primary, to 2 primary shards and one replica of each primary shard.

The process we are going to do as follow. Wondering if we have easier way to do it?

- Reindex the original index (original - 5primary shards, 1 replica for each primaryu) to a new index with “\_new” at the back. (original\_new – 2 primary shards, 1 replica for each primary )
- Delete the original index
- Reindex the ”original\_new” back to “original” index
- Delete the original index

We have 8 nodes in our cluster, I am wondering do we still need to perform shard rebalancing in the cluster, so all the shards can spread evenly. We already have **cluster.routing.allocation.enable all** set in our cluster.

Also what is the different between **cluster.routing.allocation.enable** and **cluster.routing.rebalance.enable**. I am not able to tell the detail different between these two?

**cluster.routing.allocation.enable**  
([Dynamic](https://www.elastic.co/guide/en/elasticsearch/reference/7.x/settings.html#dynamic-cluster-setting)) Enable or disable allocation for specific kinds of shards:

all - (default) Allows shard allocation for all kinds of shards.

**cluster.routing.rebalance.enable**  
([Dynamic](https://www.elastic.co/guide/en/elasticsearch/reference/7.x/settings.html#dynamic-cluster-setting)) Enable or disable rebalancing for specific kinds of shards:

all - (default) Allows shard balancing for all kinds of shards.

---

<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 5, 2021, 3:09pm UTC](https://discuss.elastic.co/t/any-efficient-way-to-perform-shards-reduction-of-the-original-index-need-to-do-shards-rebalancing-after-shards-reduction/266574/2 "2021-04-05T15:09:01Z")

</div>

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