# Increased docs.count and store.size after Elasticsearch upgrade

**URL:** <https://discuss.elastic.co/t/increased-docs-count-and-store-size-after-elasticsearch-upgrade/226670>\
**Category:** Elasticsearch\
**Created:** [April 6, 2020, 9:59am UTC](https://discuss.elastic.co/t/increased-docs-count-and-store-size-after-elasticsearch-upgrade/226670 "2020-04-06T09:59:00Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![SerjGAmoVeR](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/serjgamover/32/45177_2.png) [@SerjGAmoVeR](https://discuss.elastic.co/u/SerjGAmoVeR)\
**Post date:** [April 6, 2020, 9:59am UTC](https://discuss.elastic.co/t/increased-docs-count-and-store-size-after-elasticsearch-upgrade/226670/1 "2020-04-06T09:59:00Z")

</div>

We have existing Elasticsearch 5.5 cluster and want to migrate to another one Elasticsearch 7+

Mapping is same for both Elasticsearch 5 and Elasticsearch 7 indices

```auto
    "mappings": {
        "properties": {
          "_all": {
            "enabled": false
          },
          "keywords_count": {
            "type": "integer"
          },
          "price_sum": {
            "type": "scaled_float",
            "scaling_factor": 100
          },
          "organic": {
            "type": "nested",
            "properties": {
              "position": {
                "type": "short"
              },
              "domain": {
                "type": "keyword"
              },
              "traffic": {
                "type": "integer"
              }
            }
          }
        }
      }

```

We fill the new index with remote reindex method. Both indices has same number of documents, returned by **\_cat/count** method ( 20 mil ), but additional data from **\_cat/indices** differs a lot

New version has bigger number of docs.count ( 2.6 bil on ES 7 vs 1.1bil on ES 5) and store.size ( 500 gb ES 7 vs 260 gb ES 5)

Cannot understand, what adds so much space requirement? Please help

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [April 6, 2020, 10:40am UTC](https://discuss.elastic.co/t/increased-docs-count-and-store-size-after-elasticsearch-upgrade/226670/2 "2020-04-06T10:40:45Z")

</div>

Can you please provide the full output of the [index stats API](https://www.elastic.co/guide/en/elasticsearch/reference/7.6/indices-stats.html) for both indices?

---

<div class="post-metadata">

**Author:** ![SerjGAmoVeR](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/serjgamover/32/45177_2.png) [@SerjGAmoVeR](https://discuss.elastic.co/u/SerjGAmoVeR)\
**Post date:** [April 6, 2020, 11:30am UTC](https://discuss.elastic.co/t/increased-docs-count-and-store-size-after-elasticsearch-upgrade/226670/3 "2020-04-06T11:30:37Z")

</div>

@Christian_Dahlqvist thanks for your reply!

Long output, please check the pastebin links

ES 5 \_stats  
[https://pastebin.com/MLwKKdTU](https://pastebin.com/MLwKKdTU)

ES 7 \_stats  
[https://pastebin.com/6tx9MC0Y](https://pastebin.com/6tx9MC0Y)

---

<div class="post-metadata">

**Author:** ![SerjGAmoVeR](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/serjgamover/32/45177_2.png) [@SerjGAmoVeR](https://discuss.elastic.co/u/SerjGAmoVeR)\
**Post date:** [April 7, 2020, 8:37am UTC](https://discuss.elastic.co/t/increased-docs-count-and-store-size-after-elasticsearch-upgrade/226670/4 "2020-04-07T08:37:04Z")

</div>

I suppose there is an error in \_cat/indices response from Elasticsearch 5.5 version

\_cat/indices shows 268.7gb store.size  
Index stats output shows 594.6gb store - and it's the same as real value on hdd

```auto
health status index uuid pri rep docs.count docs.deleted store.size pri.store.size
green open uk_2020_03 jVjreQwORMCQsmMUTpkb4g 40 0 1184215956 6269622 268.7gb 268.7gb

```

```auto
"store": {
        "size_in_bytes": 638463789329, //594.6gb
        "throttle_time_in_millis": 0
      }

```

ElasticSearch 7 stats and cat/indices output shows correct values

---

<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:** [May 5, 2020, 8:37am UTC](https://discuss.elastic.co/t/increased-docs-count-and-store-size-after-elasticsearch-upgrade/226670/5 "2020-05-05T08:37:13Z")

</div>

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