# How to drop data in logstash if ES index is not available

**URL:** <https://discuss.elastic.co/t/how-to-drop-data-in-logstash-if-es-index-is-not-available/278071>\
**Category:** Logstash\
**Created:** [July 7, 2021, 12:56pm UTC](https://discuss.elastic.co/t/how-to-drop-data-in-logstash-if-es-index-is-not-available/278071 "2021-07-07T12:56:57Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![prabhakar\_talari](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/prabhakar_talari/32/46469_2.png) [@prabhakar\_talari](https://discuss.elastic.co/u/prabhakar_talari)\
**Post date:** [July 7, 2021, 12:56pm UTC](https://discuss.elastic.co/t/how-to-drop-data-in-logstash-if-es-index-is-not-available/278071/1 "2021-07-07T12:56:57Z")

</div>

Hi All,

We do not want logstash to create indexes since we are creating indexes with custom settings / mappings. some times we are getting the data from beats to logstash but the es index is not available.

if the index is not available the logstash is keep on retrying the data to push it to elastic and not processing new data

here am trying to find a way to drop the data in logstash if the es index is not available for those events.

please help me is there any way to achieve this in logstash

Thanks,

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [July 7, 2021, 5:35pm UTC](https://discuss.elastic.co/t/how-to-drop-data-in-logstash-if-es-index-is-not-available/278071/2 "2021-07-07T17:35:10Z")

</div>

> [@prabhakar\_talari](#):
>
> is there any way to achieve this in logstash

Not that I know of. logstash has an at-least-once delivery model.

---

<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:** [August 4, 2021, 5:35pm UTC](https://discuss.elastic.co/t/how-to-drop-data-in-logstash-if-es-index-is-not-available/278071/3 "2021-08-04T17:35:45Z")

</div>

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