# Should I run filebeat from bin or etc?

**URL:** <https://discuss.elastic.co/t/should-i-run-filebeat-from-bin-or-etc/53702>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [June 22, 2016, 6:47pm UTC](https://discuss.elastic.co/t/should-i-run-filebeat-from-bin-or-etc/53702 "2016-06-22T18:47:13Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![dal](https://avatars.discourse-cdn.com/v4/letter/d/ebca7d/32.png) [@dal](https://discuss.elastic.co/u/dal)\
**Post date:** [June 22, 2016, 6:47pm UTC](https://discuss.elastic.co/t/should-i-run-filebeat-from-bin-or-etc/53702/1 "2016-06-22T18:47:13Z")

</div>

I did an rpm install of filebeat. When I run filebeat from `/usr/bin/filebeat` with `/usr/bin/filebeat start` or `/usr/bin/filebeat -c /path/to/filebeat.yml`, the shell just hangs. When I run `etc/init.d/filebeat start`, i get a message saying that it started.

However, if I use `/etc/init.d/filebeat start`, i can't pass command line arguments, such as the location of the config file. even `/etc/init.d/filebeat -h` does not work.

How should I run filebeat, with `/usr/bin/filebeat` or `/etc/init.d/filebeat start`?

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [June 22, 2016, 7:29pm UTC](https://discuss.elastic.co/t/should-i-run-filebeat-from-bin-or-etc/53702/2 "2016-06-22T19:29:31Z")

</div>

If you run `/usr/bin/filebeat` you'll be starting Filebeat in the foreground, which typically isn't what you want since it'll shut down when you close your shell. The other option starts Filebeat as a daemon with options passed according to the init script. What's of most interest to you is that it'll use /etc/filebeat/filebeat.yml as its configuration file.

This is basic Unix/Linux skills and you will save yourself a lot of time by consulting a good book on the subject.

---

<div class="post-metadata">

**Author:** ![dal](https://avatars.discourse-cdn.com/v4/letter/d/ebca7d/32.png) [@dal](https://discuss.elastic.co/u/dal)\
**Post date:** [June 22, 2016, 7:36pm UTC](https://discuss.elastic.co/t/should-i-run-filebeat-from-bin-or-etc/53702/3 "2016-06-22T19:36:43Z")

</div>

got it, thanks

---

<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 13, 2016, 6:47pm UTC](https://discuss.elastic.co/t/should-i-run-filebeat-from-bin-or-etc/53702/4 "2016-07-13T18:47:19Z")

</div>

This topic was automatically closed after 21 days. New replies are no longer allowed.
