# Disk space management

**URL:** <https://discuss.elastic.co/t/disk-space-management/6406>\
**Category:** Elasticsearch\
**Created:** [January 16, 2012, 10:52pm UTC](https://discuss.elastic.co/t/disk-space-management/6406 "2012-01-16T22:52:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![derrickburns](https://avatars.discourse-cdn.com/v4/letter/d/50afbb/32.png) [@derrickburns](https://discuss.elastic.co/u/derrickburns)\
**Post date:** [January 16, 2012, 10:52pm UTC](https://discuss.elastic.co/t/disk-space-management/6406/1 "2012-01-16T22:52:09Z")

</div>

Suppose I have a 2 node cluster and I create a new index with a single  
shard. Which node is assigned the new index? What is the algorithm? Does  
the algorithm take into consideration how much local disk space available  
(when using a local gateway)? Does the algorithm take into consideration  
how many open indices are associated with each node? Does the algorithm  
take into consideration how many closed indices are associated with each  
node?

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [January 17, 2012, 9:56am UTC](https://discuss.elastic.co/t/disk-space-management/6406/2 "2012-01-17T09:56:51Z")

</div>

The aim is to have even number of shards (of open indices) across all  
nodes. Disk space is not taken into account.

On Tue, Jan 17, 2012 at 12:52 AM, Derrick [derrickrburns@gmail.com](mailto:derrickrburns@gmail.com) wrote:

> Suppose I have a 2 node cluster and I create a new index with a single  
> shard. Which node is assigned the new index? What is the algorithm? Does  
> the algorithm take into consideration how much local disk space available  
> (when using a local gateway)? Does the algorithm take into consideration  
> how many open indices are associated with each node? Does the algorithm  
> take into consideration how many closed indices are associated with each  
> node?

---

<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:** [July 6, 2017, 3:42am UTC](https://discuss.elastic.co/t/disk-space-management/6406/3 "2017-07-06T03:42:30Z")

</div>

Closed on July 6, 2017, 3:42am UTC


