Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

http.get returns "getaddrinfo ENOTFOUND" error #5436

Closed
Labels
dnsIssues and PRs related to the dns subsystem.httpIssues or PRs related to the http subsystem.
@T94T

Description

@T94T

Hi all,
I'm trying to fix following problem since five days.
When I'm doing a

or

  • http.get(options, cb);

there's this error coming back:

HTTP 5021: SOCKET ERROR: getaddrinfo ENOTFOUND _host_ _host_:80 Error: getaddrinfo ENOTFOUND _url_ _url_:80    at errnoException (dns.js:26:10)    at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:77:26)Got error: getaddrinfo ENOTFOUND _host_ _host_:80NET 5021: destroy undefinedNET 5021: destroyNET 5021: closeNET 5021: close handleNET 5021: destroyNET 5021: already destroyed, fire error callbacksNET 5021: emit closeHTTP 5021: CLIENT socket onCloseHTTP 5021: removeSocket _host_:80: destroyed: trueHTTP 5021: HTTP socket close

When doing a https request to google.com:
Got error: connect ENETUNREACH 2a00:1450:400a:806::1014:443 - Local (:::0)

I can definitely say it's NOT a DNS or a PROXY issue.

What I testet so far:

  • changed hosts file, so no dns lookup is required
  • changed resolv.conf to use other DNS servers
  • **curl and wget requests do work**
  • **ping to destination host works**
  • reinstalled complete system
  • same node.js code works on a raspbian system

node.js sample code:

var http = require('http');var options = {  host: '_host_',  port: 80,  path: '/'};http.get(options, function(res) {  console.log("Got response: " + res.statusCode);  res.on("data", function(chunk) {    console.log("BODY: " + chunk);  });}).on('error', function(e) {  console.log("Got error: " + e.message);});
  • Version: v5.5.0
  • Platform: Linux buildroot 4.1.15 armv6l (raspberrypi)

Metadata

Metadata

Assignees

No one assigned

    Labels

    dnsIssues and PRs related to the dns subsystem.httpIssues or PRs related to the http subsystem.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp