# Can't connect to remote elasticsearch node

**URL:** <https://discuss.elastic.co/t/cant-connect-to-remote-elasticsearch-node/57943>\
**Category:** Elasticsearch\
**Created:** [August 12, 2016, 4:22pm UTC](https://discuss.elastic.co/t/cant-connect-to-remote-elasticsearch-node/57943 "2016-08-12T16:22:39Z")\
**Posts on this page:** 3\
**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:** [August 12, 2016, 4:22pm UTC](https://discuss.elastic.co/t/cant-connect-to-remote-elasticsearch-node/57943/1 "2016-08-12T16:22:39Z")

</div>

I am trying to issue curl commands from a separate vm to my elasticsearch node

```
curl -XPOST 'vmWithESInstanceRunning.com:9200/bank/account/_bulk?pretty' --data-binary @accounts.json'

```

However I continually get

`curl: (7) couldn't connect to host`

My ES instance is running (when I got to localhost9200 on the vm where the elasticsearch instance is running I see information) and I can run the above curl command from said vm but I want to run it from a separate vm.

---

<div class="post-metadata">

**Author:** ![polyfractal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/polyfractal/32/48162_2.png) [@polyfractal](https://discuss.elastic.co/u/polyfractal)\
**Post date:** [August 12, 2016, 5:04pm UTC](https://discuss.elastic.co/t/cant-connect-to-remote-elasticsearch-node/57943/2 "2016-08-12T17:04:07Z")

</div>

You'll likely need to setup port forwarding from the VM to the host machine, or from VM to VM by some kind of virtualized network. The docs for your VM software should discuss how to do that.

---

<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, 10:28pm UTC](https://discuss.elastic.co/t/cant-connect-to-remote-elasticsearch-node/57943/3 "2017-07-05T22:28:00Z")

</div>


