# Setting publish\_address for logstash

**URL:** <https://discuss.elastic.co/t/setting-publish-address-for-logstash/23071>\
**Category:** Elasticsearch\
**Created:** [April 2, 2015, 7:39pm UTC](https://discuss.elastic.co/t/setting-publish-address-for-logstash/23071 "2015-04-02T19:39:10Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sijomathew](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sijomathew](https://discuss.elastic.co/u/sijomathew)\
**Post date:** [April 2, 2015, 7:39pm UTC](https://discuss.elastic.co/t/setting-publish-address-for-logstash/23071/1 "2015-04-02T19:39:10Z")

</div>

Hi,

The machine that I run logstash process has two network interfaces (public  
and private) and it looks like the logstash process picks up my private IP  
address as the "publish\_address" by default. As I use the option "node", it  
is not able to join the cluster as this address is not visible externally.  
Master node is in a different network. Could someone suggest how can I  
specifically set the publish address for the logstash process? I know this  
option is available for the elastic search processes in its config file  
(elasticsearch.yml) but not aware of how to set this for the logstash  
process.

Thanks  
Sijo Mathew

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/b9fda42d-8036-4fbc-9fcb-e91dfce5ce1d%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/b9fda42d-8036-4fbc-9fcb-e91dfce5ce1d%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![sijomathew](https://avatars.discourse-cdn.com/v4/letter/s/53a042/32.png) [@sijomathew](https://discuss.elastic.co/u/sijomathew)\
**Post date:** [April 2, 2015, 7:58pm UTC](https://discuss.elastic.co/t/setting-publish-address-for-logstash/23071/2 "2015-04-02T19:58:12Z")

</div>

bind\_host option did the trick!

On Thursday, April 2, 2015 at 3:39:10 PM UTC-4, [mailsij...@gmail.com](mailto:mailsij...@gmail.com) wrote:

> Hi,
> 
> The machine that I run logstash process has two network interfaces (public  
> and private) and it looks like the logstash process picks up my private IP  
> address as the "publish\_address" by default. As I use the option "node", it  
> is not able to join the cluster as this address is not visible externally.  
> Master node is in a different network. Could someone suggest how can I  
> specifically set the publish address for the logstash process? I know this  
> option is available for the Elasticsearch processes in its config file  
> (elasticsearch.yml) but not aware of how to set this for the logstash  
> process.
> 
> Thanks  
> Sijo Mathew

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/ec56feca-62db-49e5-8e50-a29880cc3da9%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/ec56feca-62db-49e5-8e50-a29880cc3da9%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![danilo\_gimenez\_ramos](https://avatars.discourse-cdn.com/v4/letter/d/c6cbf5/32.png) [@danilo\_gimenez\_ramos](https://discuss.elastic.co/u/danilo_gimenez_ramos)\
**Post date:** [November 18, 2015, 12:58pm UTC](https://discuss.elastic.co/t/setting-publish-address-for-logstash/23071/3 "2015-11-18T12:58:11Z")

</div>

Now I understand!

I put the bind\_host setting on the output section, and now it is working!

An excerpt of my logstash.conf:  
output {  
if "127.0.0.1" not in [message] {  
elasticsearch {  
host =\> "elasticsearch-server"  
index =\> "logstash-haproxy-bsa-provserpro-%{+YYYY.MM.dd}"  
cluster =\> "elasticsearch-diretorio"  
bind\_host =\> "this-logstash-server"  
}  
}  
}

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 5, 2017, 11:37pm UTC](https://discuss.elastic.co/t/setting-publish-address-for-logstash/23071/4 "2017-07-05T23:37:35Z")

</div>


