# How to prevent filebeat exiting when Elasticsearch server is offline

**URL:** <https://discuss.elastic.co/t/how-to-prevent-filebeat-exiting-when-elasticsearch-server-is-offline/187694>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [June 27, 2019, 1:22am UTC](https://discuss.elastic.co/t/how-to-prevent-filebeat-exiting-when-elasticsearch-server-is-offline/187694 "2019-06-27T01:22:18Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dylan\_Nicholson](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dylan_nicholson/32/45360_2.png) [@Dylan\_Nicholson](https://discuss.elastic.co/u/Dylan_Nicholson)\
**Post date:** [June 27, 2019, 1:22am UTC](https://discuss.elastic.co/t/how-to-prevent-filebeat-exiting-when-elasticsearch-server-is-offline/187694/1 "2019-06-27T01:22:18Z")

</div>

I've noticed quite a few times recently that the filebeat service just shuts down due to Elasticsearch server downtime. Basically the last line in the filebeat.log is  
"Exiting: couldn't connect to any of the configured Elasticsearch hosts"  
Is there really no way to configure filebeat to just keep retrying indefinitely? I basically never want filebeat to shut down, even if Elasticsearch goes offline for any reason or length of time.

---

<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 25, 2019, 1:22am UTC](https://discuss.elastic.co/t/how-to-prevent-filebeat-exiting-when-elasticsearch-server-is-offline/187694/2 "2019-07-25T01:22:25Z")

</div>

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