# Max\_doc, deleted\_docs and size number jump up and down

**URL:** <https://discuss.elastic.co/t/max-doc-deleted-docs-and-size-number-jump-up-and-down/5710>\
**Category:** Elasticsearch\
**Created:** [October 27, 2011, 7:05pm UTC](https://discuss.elastic.co/t/max-doc-deleted-docs-and-size-number-jump-up-and-down/5710 "2011-10-27T19:05:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Liyu](https://avatars.discourse-cdn.com/v4/letter/l/ba9def/32.png) [@Liyu](https://discuss.elastic.co/u/Liyu)\
**Post date:** [October 27, 2011, 7:05pm UTC](https://discuss.elastic.co/t/max-doc-deleted-docs-and-size-number-jump-up-and-down/5710/1 "2011-10-27T19:05:57Z")

</div>

Hi,

We are having a process feeding the logs into our ES server (single  
node, 5 shards, vanilla setup). One thing puzzles us is that the  
max\_doc, deleted\_docs and size number are jumping up and down in "ES  
head" (by \>1000 documents).

The num\_docs appears OK though, and we are pretty sure no delete  
operation is there.

Is this expected? What is the reason?

Thanks and regards,

-- Liyu

---

<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:** [October 27, 2011, 7:12pm UTC](https://discuss.elastic.co/t/max-doc-deleted-docs-and-size-number-jump-up-and-down/5710/2 "2011-10-27T19:12:28Z")

</div>

If you are reindexing the same doc, it ends up deleting the previous doc and  
indexing the new doc. Also, as internal merges happen within the index to  
maintain it, those number may change as well.

On Thu, Oct 27, 2011 at 9:05 PM, Liyu [liyuyi@gmail.com](mailto:liyuyi@gmail.com) wrote:

> Hi,
> 
> We are having a process feeding the logs into our ES server (single  
> node, 5 shards, vanilla setup). One thing puzzles us is that the  
> max\_doc, deleted\_docs and size number are jumping up and down in "ES  
> head" (by \>1000 documents).
> 
> The num\_docs appears OK though, and we are pretty sure no delete  
> operation is there.
> 
> Is this expected? What is the reason?
> 
> Thanks and regards,
> 
> -- Liyu

---

<div class="post-metadata">

**Author:** ![spokarna](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@spokarna](https://discuss.elastic.co/u/spokarna)\
**Post date:** [October 30, 2011, 8:49am UTC](https://discuss.elastic.co/t/max-doc-deleted-docs-and-size-number-jump-up-and-down/5710/3 "2011-10-30T08:49:30Z")

</div>

I had noticed this in my setup and problem turned out that I was inserting records with duplicate ids.  
I was not noticing numbers jump up and down though, and total of numdocs and deleted docs was equal to the number of docs that i had inserted...

-----Original message-----  
From: Liyu  
Sent: 28/10/2011, 12:35 am  
To: elasticsearch  
Subject: max\_doc, deleted\_docs and size number jump up and down

Hi,

We are having a process feeding the logs into our ES server (single  
node, 5 shards, vanilla setup). One thing puzzles us is that the  
max\_doc, deleted\_docs and size number are jumping up and down in "ES  
head" (by \>1000 documents).

The num\_docs appears OK though, and we are pretty sure no delete  
operation is there.

Is this expected? What is the reason?

Thanks and regards,

-- Liyu

---

<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:50am UTC](https://discuss.elastic.co/t/max-doc-deleted-docs-and-size-number-jump-up-and-down/5710/4 "2017-07-06T03:50:27Z")

</div>


