# Running LogStash with Beats as Service, stops with Address in use

**URL:** https://discuss.elastic.co/t/running-logstash-with-beats-as-service-stops-with-address-in-use/36029
**Category:** Beats
**Created:** [December 1, 2015, 10:37am UTC](https://discuss.elastic.co/t/running-logstash-with-beats-as-service-stops-with-address-in-use/36029 "2015-12-01T10:37:45Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Adrian\_Martin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adrian_martin/32/6167_2.png) [@Adrian\_Martin](https://discuss.elastic.co/u/Adrian_Martin)
#### Post date: [December 1, 2015, 10:37am UTC](https://discuss.elastic.co/t/running-logstash-with-beats-as-service-stops-with-address-in-use/36029/1 "2015-12-01T10:37:45Z")

</div>

I've added --debug to the the rc options and get

```
{:timestamp=>"2015-12-01T10:26:16.175000+0000", :message=>"Starting Beats input listener", :address=>"0.0.0.0:5044", :level=>:info}
{:timestamp=>"2015-12-01T10:26:16.182000+0000", :message=>"The error reported is: \n Address already in use - bind - Address already in use"}
{:timestamp=>"2015-12-01T10:32:41.773000+0000", :message=>"Reading config file", :config_file=>"/etc/logstash/conf.d/beat.conf", :level=>:debug, :file=>"logstash/agent.rb", :line=>"325", :method=>"local_config"}

```

so it wont run as a service.....

there is only one file in conf.d...and it runs fine from the command line...

do I need to specify the machines fqn in the beats input?

---

<div class="post-metadata">

### Author: ![tudor](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tudor/32/3753_2.png) [@tudor](https://discuss.elastic.co/u/tudor)
#### Post date: [December 1, 2015, 10:39am UTC](https://discuss.elastic.co/t/running-logstash-with-beats-as-service-stops-with-address-in-use/36029/2 "2015-12-01T10:39:57Z")

</div>

Can you check if you have something else that is listening on the same port? In Linux that would be:

```
netstat -nlp | grep 5044
```

---

<div class="post-metadata">

### Author: ![Adrian\_Martin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adrian_martin/32/6167_2.png) [@Adrian\_Martin](https://discuss.elastic.co/u/Adrian_Martin)
#### Post date: [December 1, 2015, 10:45am UTC](https://discuss.elastic.co/t/running-logstash-with-beats-as-service-stops-with-address-in-use/36029/3 "2015-12-01T10:45:37Z")

</div>

was trying netstat, but didn't have those options(nlp)...

this is what I get

tcp6 0 0 :::5044 :::\* LISTEN 12428/java

---

<div class="post-metadata">

### Author: ![Adrian\_Martin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adrian_martin/32/6167_2.png) [@Adrian\_Martin](https://discuss.elastic.co/u/Adrian_Martin)
#### Post date: [December 1, 2015, 11:43am UTC](https://discuss.elastic.co/t/running-logstash-with-beats-as-service-stops-with-address-in-use/36029/4 "2015-12-01T11:43:43Z")

</div>

hmmm so that proc seems to be Logstash Agent....so it's running, are there any docs about the agent?

---

<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 5, 2017, 9:57pm UTC](https://discuss.elastic.co/t/running-logstash-with-beats-as-service-stops-with-address-in-use/36029/5 "2017-07-05T21:57:53Z")

</div>


