# Reindex vs Split Speed and Storage Requirements

**URL:** <https://discuss.elastic.co/t/reindex-vs-split-speed-and-storage-requirements/352719>\
**Category:** Elasticsearch\
**Created:** [February 7, 2024, 9:29am UTC](https://discuss.elastic.co/t/reindex-vs-split-speed-and-storage-requirements/352719 "2024-02-07T09:29:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![zalseryani](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/zalseryani/32/122438_2.png) [@zalseryani](https://discuss.elastic.co/u/zalseryani)\
**Post date:** [February 7, 2024, 9:29am UTC](https://discuss.elastic.co/t/reindex-vs-split-speed-and-storage-requirements/352719/1 "2024-02-07T09:29:12Z")

</div>

I have seen a previous topic discussing the difference in speed between reindexing and splitting for an index [Reindex vs Split index speeds](https://discuss.elastic.co/t/reindex-vs-split-index-speeds/320779)

- if splitting is much faster than reindexing since it is hard-linking the underlying files of the index, **why does splitting need 3 - 4 times of storage when it is using the hard links ?**

I appreciate your time and support.

---

<div class="post-metadata">

**Author:** ![DavidTurner](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/davidturner/32/22453_2.png) [@DavidTurner](https://discuss.elastic.co/u/DavidTurner)\
**Post date:** [February 8, 2024, 9:43am UTC](https://discuss.elastic.co/t/reindex-vs-split-speed-and-storage-requirements/352719/2 "2024-02-08T09:43:06Z")

</div>

The hard-linking phase makes starting up the split shards fast, but the resulting shards contain all the docs from all the other shards too, in a deleted state, but those deleted docs make them a little inefficient at first. Once the shards have been started, a background merge addresses this by rewriting the shard contents in a more efficient form, removing all the deleted docs. While the merge is ongoing it must hold on disk both the old unmerged (hard-linked) data and the new (rewritten) data, plus various temporary files, and in extreme cases this can temporarily need some multiple of the original shard size. Often it doesn't.

---

<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:** [March 7, 2024, 9:43am UTC](https://discuss.elastic.co/t/reindex-vs-split-speed-and-storage-requirements/352719/3 "2024-03-07T09:43:54Z")

</div>

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