Error: getaddrinfo ENOTFOUND

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"\n// msg.url = '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

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.

@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.

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?

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.