# Failed to connect logstash

**URL:** <https://discuss.elastic.co/t/failed-to-connect-logstash/169135>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [February 20, 2019, 6:00am UTC](https://discuss.elastic.co/t/failed-to-connect-logstash/169135 "2019-02-20T06:00:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ani](https://avatars.discourse-cdn.com/v4/letter/a/35a633/32.png) [@Ani](https://discuss.elastic.co/u/Ani)\
**Post date:** [February 20, 2019, 6:00am UTC](https://discuss.elastic.co/t/failed-to-connect-logstash/169135/1 "2019-02-20T06:00:46Z")

</div>

Hi ,  
Filebeat is not able to send data to logstash server , I am getting below error from filebeat.log file

Failed to connect: Get **http://**.20. **.70:5044:** read tcp **20.**.62:35480-\> **.20.**.70:5044: read: connection reset by peer"

But,  
telnet to 5044 works fine  
firewall is off on both machines.  
selinux is disabled.

Can you someone suggest how to trouble shoot this?

---

<div class="post-metadata">

**Author:** ![steffens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/steffens/32/79630_2.png) [@steffens](https://discuss.elastic.co/u/steffens)\
**Post date:** [February 20, 2019, 4:08pm UTC](https://discuss.elastic.co/t/failed-to-connect-logstash/169135/2 "2019-02-20T16:08:56Z")

</div>

The connection is established, but eventually closed by Logstash or the machine Logstash runs on. When Filebeat tries to publish it get a 'TCP RST' package notifying it the connection has actually been closed.

Which Logstash/Filebeat versions are you using?

Is there a chance filebeat didn't send any data for a "long" time?

Normally filebeat tries to reconnect. No events are dropped.

---

<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:** [March 20, 2019, 4:08pm UTC](https://discuss.elastic.co/t/failed-to-connect-logstash/169135/3 "2019-03-20T16:08:57Z")

</div>

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