# Where configure custom ElasticSearch host

**URL:** <https://discuss.elastic.co/t/where-configure-custom-elasticsearch-host/62685>\
**Category:** Beats\
**Tags:** beats-development\
**Created:** [October 11, 2016, 7:22am UTC](https://discuss.elastic.co/t/where-configure-custom-elasticsearch-host/62685 "2016-10-11T07:22:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Premislauer](https://avatars.discourse-cdn.com/v4/letter/p/e19b73/32.png) [@Premislauer](https://discuss.elastic.co/u/Premislauer)\
**Post date:** [October 11, 2016, 7:22am UTC](https://discuss.elastic.co/t/where-configure-custom-elasticsearch-host/62685/1 "2016-10-11T07:22:49Z")

</div>

Hi, I'm new to libbeat and i'm trying to prepare some example to working with my elasticsearch host. But i don't know where is the right place to configure host. I thought that it should be etc/beat.yml but when i do "make update" in mybeat.yml i got two entries with host:  
output.elasticsearch:  
hosts: ["[http://myhost:9200](http://myhost:9200)"]  
and default from vendor/github.com/elastic/beats/libbeat/\_meta/config.yml  
output.elasticsearch:

# Array of hosts to connect to.

hosts: ["localhost:9200"]

Where should i configure hosts to not need to edit mybeat.yml after "make update"?  
Regards

---

<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:** [October 11, 2016, 11:00am UTC](https://discuss.elastic.co/t/where-configure-custom-elasticsearch-host/62685/2 "2016-10-11T11:00:58Z")

</div>

`make update` loads the libbeat based settings from beats/libbeat/\_meta/config\*.yml . These are the global defaults used to build the standard sample config file.

Normally you're not supposed to update this file, as this is the default for packaging. Usually I copy and update the generated file for my tests =\> having a special directory with multiple configurations. With beats 5.0 one can use `-c ...` flag multiple times using a second config file overwriting the defaults. This is quite convenient for testing. Alternatively one can overwrite any setting via `-E`. E.g. run your beat like:

```auto
./mybeat -c mybeat.yml -E output.elasticsearch.hosts="http://myhost:9200"

```

or assuming a separate config file with content:

```auto
output.elasticsearch.hosts = ["http://myhost:9200"]

```

can be used like this:

```auto
./mybeat -c mybeat.yml -c myhost.output.yml

```

---

<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 1, 2016, 7:22am UTC](https://discuss.elastic.co/t/where-configure-custom-elasticsearch-host/62685/3 "2016-11-01T07:22:56Z")

</div>

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