# Logstash refusing connection error

**URL:** <https://discuss.elastic.co/t/logstash-refusing-connection-error/345708>\
**Category:** Logstash\
**Tags:** elastic-stack-monitoring\
**Created:** [October 25, 2023, 9:35am UTC](https://discuss.elastic.co/t/logstash-refusing-connection-error/345708 "2023-10-25T09:35:47Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vaishalik03](https://avatars.discourse-cdn.com/v4/letter/v/278dde/32.png) [@vaishalik03](https://discuss.elastic.co/u/vaishalik03)\
**Post date:** [October 25, 2023, 9:35am UTC](https://discuss.elastic.co/t/logstash-refusing-connection-error/345708/1 "2023-10-25T09:35:47Z")

</div>

Hi All,

I'm trying to connect to Kibana after running the logstash but could see that the connection is getting refused after running the file.  
Following are the responses on batch.  
Could you please let me know when and why does this error occur.

//  
log [06:30:52.310] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:30:53.535] [warning][elasticsearch][monitoring] Unable to revive connection: [http://a0310pnpbiapp02:9200/](http://a0310pnpbiapp02:9200/)  
log [06:30:53.536] [warning][elasticsearch][monitoring] No living connections  
log [06:30:53.540] [warning][licensing][plugins] License information could not be obtained from Elasticsearch due to Error: No Living connections error  
log [06:30:57.322] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:02.336] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:07.333] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:12.352] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:17.387] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:22.417] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:23.547] [warning][elasticsearch][monitoring] Unable to revive connection: [http://a0310pnpbiapp02:9200/](http://a0310pnpbiapp02:9200/)  
log [06:31:23.548] [warning][elasticsearch][monitoring] No living connections  
log [06:31:23.552] [warning][licensing][plugins] License information could not be obtained from Elasticsearch due to Error: No Living connections error  
log [06:31:27.412] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:32.430] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:37.450] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:42.476] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:47.479] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:52.484] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200  
log [06:31:53.568] [warning][elasticsearch][monitoring] Unable to revive connection: [http://a0310pnpbiapp02:9200/](http://a0310pnpbiapp02:9200/)  
log [06:31:53.569] [warning][elasticsearch][monitoring] No living connections  
log [06:31:53.570] [warning][licensing][plugins] License information could not be obtained from Elasticsearch due to Error: No Living connections error  
log [06:31:57.492] [error][data][elasticsearch] [ConnectionError]: connect ECONNREFUSED 172.31.201.229:9200

---

<div class="post-metadata">

**Author:** ![ashishtiwari1993](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ashishtiwari1993/32/135241_2.png) [@ashishtiwari1993](https://discuss.elastic.co/u/ashishtiwari1993)\
**Post date:** [October 25, 2023, 9:42am UTC](https://discuss.elastic.co/t/logstash-refusing-connection-error/345708/2 "2023-10-25T09:42:21Z")

</div>

HI @vaishalik03, Welcome to the Elastic community.

Could you first try to connect with `curl` command from the same machine ? Let's make sure there is no firewall blocker or any.

---

<div class="post-metadata">

**Author:** ![Rios](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rios/32/95745_2.png) [@Rios](https://discuss.elastic.co/u/Rios)\
**Post date:** [October 25, 2023, 12:43pm UTC](https://discuss.elastic.co/t/logstash-refusing-connection-error/345708/3 "2023-10-25T12:43:08Z")

</div>

1. firewall, opened port 9200,
2. `network.host: 0.0.0.0` in elasticsearch.yml
3. Check does ES use http or https- [http://a0310pnpbiapp02:9200/](http://a0310pnpbiapp02:9200/)

---

<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:** [November 22, 2023, 12:43pm UTC](https://discuss.elastic.co/t/logstash-refusing-connection-error/345708/4 "2023-11-22T12:43:58Z")

</div>

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