question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error: getaddrinfo ENOTFOUND iZ94st1428jZ iZ94st1428jZ:4150

See original GitHub issue

curl ok

$ curl -d "ssssgfsadfgsdfsdfsfgddsf"  "http://120.24.210.90:4151/put?topic=test"
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100    26  100     2  100    24     25    307 --:--:-- --:--:-- --:--:--   307OK

run error

$ node .
events.js:141
      throw er; // Unhandled 'error' event
      ^

Error: getaddrinfo ENOTFOUND iZ94st1428jZ iZ94st1428jZ:4150
    at errnoException (dns.js:26:10)
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:77:26)

code

var nsq = require('nsqjs');
var reader = new nsq.Reader('topic', 'test', {
  lookupdHTTPAddresses: '120.24.210.90:4161'
});

reader.connect();

reader.on('message', function (msg) {
  console.log('Received message [%s]: %s', msg.id, msg.body.toString());
  msg.finish();
});

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

4reactions
dudleycarrcommented, Jun 3, 2018

You need to use the --broadcast-address=127.0.0.1 option on nsqd. What’s happening is that nsqlookupd is telling nsqjs to connect to nsqd:4150 which means nothing to a client running on your host machine. Obviously, once you dockerize the NodeJS process, then you’ll want to remove the --broadcast-address

0reactions
janbaercommented, Jun 4, 2018

Thank you, it solved my problem!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error: getaddrinfo ENOTFOUND in nodejs for get call
getaddrinfo ENOTFOUND means client was not able to connect to given address. Please try specifying host without http: var optionsget = { host...
Read more >
Node.js Error Message “getaddrinfo ENOTFOUND localhost ...
If you try to run your JSON server and see this error message “getaddrinfo ENOTFOUND localhost,” it's happening because Webpack cannot find your...
Read more >
Mongodb remote database connectivity error - getaddrinfo ...
I am getting following error: getaddrinfo ENOTFOUND mycluster-u8ha7.mongodb.net. Can someone pls guide me how to troubleshoot and make this ...
Read more >
Host(s) Unable to Connect to Management Plane With "Error
Host(s) Unable to Connect to Management Plane With "Error: getaddrinfo ENOTFOUND. Problem. Host(s) are unable to remain online from the Management Plane's ...
Read more >
Encountering Error: getaddrinfo ENOTFOUND undefine...
Encountering Error: getaddrinfo ENOTFOUND undefined undefined:443 while configuring Excel Report Add-On for ArcGIS Monitor.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found