# Error: getaddrinfo ENOTFOUND

**URL:** <https://discourse.nodered.org/t/error-getaddrinfo-enotfound/11754>\
**Category:** General\
**Created:** [1 June 2019 19:36 UTC](https://discourse.nodered.org/t/error-getaddrinfo-enotfound/11754 "2019-06-01T19:36:30Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![HKKKK](https://avatars.discourse-cdn.com/v4/letter/h/5f9b8f/32.png) [@HKKKK](https://discourse.nodered.org/u/HKKKK)\
**Post date:** [1 June 2019 19:36 UTC](https://discourse.nodered.org/t/error-getaddrinfo-enotfound/11754/1 "2019-06-01T19:36:30Z")

</div>

In node-red, when using the http-request node with the following url `http://dccxc072.pok.ibm.com:4001/demo`, I get the following error  
`Error: getaddrinfo ENOTFOUND dccxc072.pok.ibm.com dccxc072.pok.ibm.com:4001`

Any idea, what causes this error and how it can be resolved?

The flow is as follows  
[{"id":"d3ca76af.f83d18","type":"function","z":"1b29e658.48d1fa","name":"","func":"payload = {"prompt":"w"}\nmsg.payload = payload;\nmsg.headers = {\n "Content-type" : "application/json"\n};\nmsg.method = "POST"\nmsg.url = "[http://dccxc072.pok.ibm.com:4001/demo](http://dccxc072.pok.ibm.com:4001/demo)"\n// msg.url = '[http://virtualarchitect.sl.cloud9.ibm.com:3010/faq/what%20is%20rcp](http://virtualarchitect.sl.cloud9.ibm.com:3010/faq/what%20is%20rcp)'\n// msg.url = 'localhost:4011/sqdemo'\nnode.warn(msg)\n\nreturn msg;","outputs":1,"noerr":0,"x":563,"y":65,"wires":[["12fcafc.2f96fd","11cdd984.a8dbe6"]]}]

The above URL is working with POSTMAN

Thanks

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [1 June 2019 20:00 UTC](https://discourse.nodered.org/t/error-getaddrinfo-enotfound/11754/2 "2019-06-01T20:00:55Z")

</div>

You need to follow the instructions below when posting a flow. Please re-post, but also make a complete working flow for us to test, with an inject node, the function node and the request node. Then we can easily test the flow.

> [@How to share code or flow json](https://discourse.nodered.org/t/how-to-share-code-or-flow-json/506):
>
> To share code samples or flow json in this forum, you need to take care to format it properly so that it is displayed correctly. The easiest way to do that is to click the 'Preformatted Text' button in the toolbar: [image] Then paste in your code or flow json. You should end up with three back-tick characters - ``` - on their own line before and after the code. On standard US English keyboards, this is on the same key as the ~ character. Using the backticks will ens…

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [1 June 2019 20:04 UTC](https://discourse.nodered.org/t/error-getaddrinfo-enotfound/11754/3 "2019-06-01T20:04:40Z")

</div>

@HKKKK where exactly is this flow running? Is it running on the IBM Cloud?

It is trying to access a url that is only available (I believe) on the IBM internal network. If you flow is running on IBM Cloud then it will not be able to reach that URL. Postman is presumably running on your laptop which _is_ connected to the vpn.

---

<div class="post-metadata">

**Author:** ![HKKKK](https://avatars.discourse-cdn.com/v4/letter/h/5f9b8f/32.png) [@HKKKK](https://discourse.nodered.org/u/HKKKK)\
**Post date:** [2 June 2019 02:35 UTC](https://discourse.nodered.org/t/error-getaddrinfo-enotfound/11754/4 "2019-06-02T02:35:29Z")

</div>

Thanks @knolleary, i understand the problem. Really appreciate it.  
Yes, I am running the node-red flow on IBM Cloud, and the URL that the flow is trying to access is only available on the IBM internal network.

Is there any solution to it?

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [2 June 2019 06:09 UTC](https://discourse.nodered.org/t/error-getaddrinfo-enotfound/11754/5 "2019-06-02T06:09:02Z")

</div>

Not in that configuration. No. If there was IBM security would want to know about it.. You need to move Node-RED to be inside the firewall.
