# HTTP Input/Output

**URL:** <https://discuss.elastic.co/t/http-input-output/281593>\
**Category:** Logstash\
**Created:** [August 16, 2021, 7:28pm UTC](https://discuss.elastic.co/t/http-input-output/281593 "2021-08-16T19:28:27Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![tofubeats](https://avatars.discourse-cdn.com/v4/letter/t/9fc348/32.png) [@tofubeats](https://discuss.elastic.co/u/tofubeats)\
**Post date:** [August 16, 2021, 7:28pm UTC](https://discuss.elastic.co/t/http-input-output/281593/1 "2021-08-16T19:28:27Z")

</div>

Hello,

I am working on connecting two instances of logstash by an HTTP plugin.

On node 1, the config is set to ingest from a CSV and outputs those docs to a local HTTP url. As in, the URL is set to a port on node 1.

On node 2, the config's HTTP input is set to connect to the URL on node 1.

I keep getting vague errors about this, such as the plugin had an unrecoverable error and that a thread was rejected. I Was wondering if the HTTP input plugin's "host" option can only be set to local hosts and cannot connect to other hosts, like how I am trying to set "host" on node 2 to connect to node 1? Should it be the other way around?

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [August 16, 2021, 7:35pm UTC](https://discuss.elastic.co/t/http-input-output/281593/2 "2021-08-16T19:35:50Z")

</div>

A logstash http input creates an http server that listens on a local address. You can use a remote value for host.

If you want logstash to connect to an http server as a client then use an http\_poller input.

---

<div class="post-metadata">

**Author:** ![tofubeats](https://avatars.discourse-cdn.com/v4/letter/t/9fc348/32.png) [@tofubeats](https://discuss.elastic.co/u/tofubeats)\
**Post date:** [August 17, 2021, 7:46pm UTC](https://discuss.elastic.co/t/http-input-output/281593/3 "2021-08-17T19:46:09Z")

</div>

Thank you! I did end up using http\_poller, but now I'm realizing the http output is not an http server, is this correct? Does directing http\_poller to an http output URL not work?

I'm asking this because I keep getting the following error:  
`[HTTP Output Failure] Could not fetch URL`

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [August 17, 2021, 8:00pm UTC](https://discuss.elastic.co/t/http-input-output/281593/4 "2021-08-17T20:00:00Z")

</div>

> [@tofubeats](#):
>
> I'm realizing the http output is not an http server, is this correct?

Correct. An http output is an http client.

You can connect two logstash instances using an http output and an http input. However, the [recommended method](https://www.elastic.co/guide/en/logstash/current/ls-to-ls.html) is a lumberjack output and a beats input.

---

<div class="post-metadata">

**Author:** ![tofubeats](https://avatars.discourse-cdn.com/v4/letter/t/9fc348/32.png) [@tofubeats](https://discuss.elastic.co/u/tofubeats)\
**Post date:** [August 17, 2021, 8:59pm UTC](https://discuss.elastic.co/t/http-input-output/281593/5 "2021-08-17T20:59:13Z")

</div>

Thank you! I appreciate the guidance on this

---

<div class="post-metadata">

**Author:** ![tofubeats](https://avatars.discourse-cdn.com/v4/letter/t/9fc348/32.png) [@tofubeats](https://discuss.elastic.co/u/tofubeats)\
**Post date:** [August 18, 2021, 9:20pm UTC](https://discuss.elastic.co/t/http-input-output/281593/6 "2021-08-18T21:20:38Z")

</div>

This might be a silly question but is there a reason why setting the host IP in the http input plugin to a remote host still only opens the port up locally?

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [August 18, 2021, 10:20pm UTC](https://discuss.elastic.co/t/http-input-output/281593/7 "2021-08-18T22:20:26Z")

</div>

In my experience it does not do so.

---

<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:** [September 15, 2021, 10:20pm UTC](https://discuss.elastic.co/t/http-input-output/281593/8 "2021-09-15T22:20:52Z")

</div>

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