# Connection could be made because the target machine actively refused it

**URL:** <https://discuss.elastic.co/t/connection-could-be-made-because-the-target-machine-actively-refused-it/208151>\
**Category:** Beats\
**Tags:** winlogbeat\
**Created:** [November 16, 2019, 9:24am UTC](https://discuss.elastic.co/t/connection-could-be-made-because-the-target-machine-actively-refused-it/208151 "2019-11-16T09:24:35Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Coder\_HK](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/coder_hk/32/57814_2.png) [@Coder\_HK](https://discuss.elastic.co/u/Coder_HK)\
**Post date:** [November 16, 2019, 9:24am UTC](https://discuss.elastic.co/t/connection-could-be-made-because-the-target-machine-actively-refused-it/208151/1 "2019-11-16T09:24:35Z")

</div>

I am running windows 10 as my main OS and Ubuntu in Vm ware.. I have installed ELK on ubuntu and now I want to move Sysmon/winlogbeat logs to logstash but I am getting the error ..

every thing is running .. E,L,K

---

<div class="post-metadata">

**Author:** ![adrisr](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adrisr/32/25423_2.png) [@adrisr](https://discuss.elastic.co/u/adrisr)\
**Post date:** [November 26, 2019, 11:22am UTC](https://discuss.elastic.co/t/connection-could-be-made-because-the-target-machine-actively-refused-it/208151/2 "2019-11-26T11:22:13Z")

</div>

It looks like a networking problem between your VM guest and the Windows host.

Make sure that:

- you're using the right IP address for accessing the VM from the Windows OS
- traffic to Logstash port is allowed from outside the VM
- Logstash is listening on all interfaces (`0.0.0.0`) and not to `localhost` / `127.0.0.1`.

---

<div class="post-metadata">

**Author:** ![Coder\_HK](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/coder_hk/32/57814_2.png) [@Coder\_HK](https://discuss.elastic.co/u/Coder_HK)\
**Post date:** [November 27, 2019, 4:20am UTC](https://discuss.elastic.co/t/connection-could-be-made-because-the-target-machine-actively-refused-it/208151/3 "2019-11-27T04:20:47Z")

</div>

everything in Logstash.yml is commented out which means every setting is default. now what's default listening setting for logstash ?  
and as far as the traffic from outside issue is concerned I think it's allowed coz I can ping it from outside.

---

<div class="post-metadata">

**Author:** ![stefws](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stefws/32/6442_2.png) [@stefws](https://discuss.elastic.co/u/stefws)\
**Post date:** [December 7, 2019, 7:51pm UTC](https://discuss.elastic.co/t/connection-could-be-made-because-the-target-machine-actively-refused-it/208151/4 "2019-12-07T19:51:56Z")

</div>

Check your ubuntu with these CLIs:

```
netstat -lntp
iptables -L
```

---

<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 4, 2020, 7:51pm UTC](https://discuss.elastic.co/t/connection-could-be-made-because-the-target-machine-actively-refused-it/208151/5 "2020-01-04T19:51:58Z")

</div>

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