# Best way to "sample" an ES cluster for testing

**URL:** <https://discuss.elastic.co/t/best-way-to-sample-an-es-cluster-for-testing/68774>\
**Category:** Elasticsearch\
**Created:** [December 12, 2016, 9:16pm UTC](https://discuss.elastic.co/t/best-way-to-sample-an-es-cluster-for-testing/68774 "2016-12-12T21:16:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mhughes](https://avatars.discourse-cdn.com/v4/letter/m/85e7bf/32.png) [@mhughes](https://discuss.elastic.co/u/mhughes)\
**Post date:** [December 12, 2016, 9:16pm UTC](https://discuss.elastic.co/t/best-way-to-sample-an-es-cluster-for-testing/68774/1 "2016-12-12T21:16:39Z")

</div>

I have an ES cluster with ~500 indices and 3TB of data. I'm looking for the best way to sample data from this cluster into a much smaller test cluster for testing upgrades.

I don't need _all_ the data in my test cluster. I just want to sample N number of documents from each index. Any good way to do that? I looked at logstash but didn't see any obvious way to get "the first 10K records" from the elasticsearch input plugin. Am I missing something? Some other tool out there that will do this for me?

---

<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:** [January 9, 2017, 9:16pm UTC](https://discuss.elastic.co/t/best-way-to-sample-an-es-cluster-for-testing/68774/2 "2017-01-09T21:16:42Z")

</div>

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