# Scroll id questions

**URL:** https://discuss.elastic.co/t/scroll-id-questions/82967
**Category:** Elasticsearch
**Created:** [April 20, 2017, 2:18am UTC](https://discuss.elastic.co/t/scroll-id-questions/82967 "2017-04-20T02:18:04Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![ginger](https://avatars.discourse-cdn.com/v4/letter/g/34f0e0/32.png) [@ginger](https://discuss.elastic.co/u/ginger)
#### Post date: [April 20, 2017, 2:18am UTC](https://discuss.elastic.co/t/scroll-id-questions/82967/1 "2017-04-20T02:18:04Z")

</div>

Hi.

I'm using scroll to export data from es 5.0.0, and I have a few questions:

1. The reference says:  
"The initial search request and each subsequent scroll request returns a new \_scroll\_id — only the most recent \_scroll\_id should be used."

While in test, the initial search request and each subsequent scroll request returns the same \_scroll\_id.

1. When I try to clear scroll:

> ```
> DELETE /_search/scroll
> {
> "scroll_id" : "DnF1ZXJ5VGhlbkZldGNoFAAAAAAAG3Z7FmtGVmdXb2RKUzUyaGZ0dkxLajJxUWcAAAAAAACcnxZ6ZWdHMWw3alRQeXZ0UHllN2czblJRAAAAAAAOEpMWZ1hZZG5odVNSdy01TG40dFBzc2JWZwAAAAAADhKPFk9PTThraVZ2UXF5S2xETVJwYVdnbXcAAAAAAAC--BZ0VEJvMTBHbVNxZTgwNEtzSExZNVh3AAAAAAAbdnwWa0ZWZ1dvZEpTNTJoZnR2TEtqMnFRZwAAAAAAAJygFnplZ0cxbDdqVFB5dnRQeWU3ZzNuUlEAAAAAAA4SlBZnWFlkbmh1U1J3LTVMbjR0UHNzYlZnAAAAAAAOEpAWT09NOGtpVnZRcXlLbERNUnBhV2dtdwAAAAAAAL75FnRUQm8xMEdtU3FlODA0S3NITFk1WHcAAAAAABt2fRZrRlZnV29kSlM1MmhmdHZMS2oycVFnAAAAAAAAnKEWemVnRzFsN2pUUHl2dFB5ZTdnM25SUQAAAAAADhKVFmdYWWRuaHVTUnctNUxuNHRQc3NiVmcAAAAAAA4SkRZPT004a2lWdlFxeUtsRE1ScGFXZ213AAAAAAAAvvoWdFRCbzEwR21TcWU4MDRLc0hMWTVYdwAAAAAAG3Z-FmtGVmdXb2RKUzUyaGZ0dkxLajJxUWcAAAAAAACcohZ6ZWdHMWw3alRQeXZ0UHllN2czblJRAAAAAAAOEpYWZ1hZZG5odVNSdy01TG40dFBzc2JWZwAAAAAADhKSFk9PTThraVZ2UXF5S2xETVJwYVdnbXcAAAAAAAC--xZ0VEJvMTBHbVNxZTgwNEtzSExZNVh3"
> }
> 
> ```

I always get the following:

> {  
> "error": {  
> "root\_cause": [  
> {  
> "type": "action\_request\_validation\_exception",  
> "reason": "Validation Failed: 1: no scroll ids specified;"  
> }  
> ],  
> "type": "action\_request\_validation\_exception",  
> "reason": "Validation Failed: 1: no scroll ids specified;"  
> },  
> "status": 400  
> }

Need I clear the last scroll id after each subsequent scroll request?  
Any help would be appreciated!

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [April 20, 2017, 7:54am UTC](https://discuss.elastic.co/t/scroll-id-questions/82967/2 "2017-04-20T07:54:38Z")

</div>

> [@ginger](#):
>
> Need I clear the last scroll id after each subsequent scroll request?

Nope, requesting the new ID auto clears the old one.

---

<div class="post-metadata">

### Author: ![ginger](https://avatars.discourse-cdn.com/v4/letter/g/34f0e0/32.png) [@ginger](https://discuss.elastic.co/u/ginger)
#### Post date: [April 20, 2017, 12:00pm UTC](https://discuss.elastic.co/t/scroll-id-questions/82967/3 "2017-04-20T12:00:53Z")

</div>

Thanks very much!  
Hope the reference can be more clearly : )

---

<div class="post-metadata">

### Author: ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)
#### Post date: [April 20, 2017, 11:38pm UTC](https://discuss.elastic.co/t/scroll-id-questions/82967/4 "2017-04-20T23:38:43Z")

</div>

I raised [https://github.com/elastic/elasticsearch/pull/24204](https://github.com/elastic/elasticsearch/pull/24204) to clarify 🙂

---

<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 18, 2017, 11:53pm UTC](https://discuss.elastic.co/t/scroll-id-questions/82967/5 "2017-05-18T23:53:39Z")

</div>

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