Skip to content

Assertion failed: (r) == (0), file src\cares_wrap.cc, line 1262 #5588

Description

@BrightLamp

When i set the Internet (TCP/IPv4) property to
IP address: 192.168.1.253 & 255.255.255.0

Node.js failed to startup:
Assertion failed: (r) == (0), file src\cares_wrap.cc, line 1262

I found this in windows10 & node.js version 5.7.0

Activity

  1. added
    lib / srcIssues and PRs involving general changes in the lib/ or src/ directories.
    on Mar 7, 2016
  2. micnic commented on Mar 7, 2016

    @micnic
    Contributor

    Do you have any minimal code to reproduce this issue?
    I tried to reproduce this by doing a HTTP request (Node 5.7.1), but everything went fine.

  3. bnoordhuis commented on Mar 7, 2016

    @bnoordhuis
    Member

    Do you have this problem with v5.5.0 as well? We upgraded c-ares (the component that does DNS), then partially reverted it again.

    I say partially because while 35c3832 got reverted in 127dd62, I see that f1a0827 is still present. v5.5.0 is the last release without that commit. /cc @indutny

  4. added
    c++Issues and PRs that require attention from people who are familiar with C++.
    dnsIssues and PRs related to the dns subsystem.
    and removed
    lib / srcIssues and PRs involving general changes in the lib/ or src/ directories.
    on Mar 7, 2016
  5. BrightLamp commented on Mar 8, 2016

    @BrightLamp
    Author

    It is a notebook computer which has not local area network(LAN), i must use the wireless local area network(WLAN) to connect my new network router i bought yesterday.
    When i set a special IP address instead of AUTO, the WLAN shows "Limited".

    Then
    "Assertion failed: (r) == (0), file src\cares_wrap.cc, line 1262"
    comes up by just double click the node.exe.

    After disable the WLAN or change IP address to AUTO, node.js runs well.

    By the way, when node5.7.1 works wrong, node5.5.0 runs well.
    Thanks.

  6. anaisbetts commented on Jul 16, 2016

    @anaisbetts

    Can we reopen this? Reverting to an older node version is not "Solved" from a bug perspective

  7. addaleax commented on Jul 16, 2016

    @addaleax
    Member

    @paulcbetts I take it you can confirm that this is still an issue in v6.3.0?

  8. added
    caresIssues and PRs related to the c-ares dependency or the cares_wrap binding.
    on Jul 16, 2016
  9. anaisbetts commented on Jul 17, 2016

    @anaisbetts

    @adamesque ^^ peep the referenced Electron bug, it seems to be something specific to a minority of systems

  10. anaisbetts commented on Jul 17, 2016

    @anaisbetts
    00 000000f8`6b7ecbb8 00007ffa`2c8fb185 ntdll!NtTerminateProcess+0x14
    01 000000f8`6b7ecbc0 00007ffa`2ad74d8a ntdll!RtlExitUserProcess+0xe5
    *** WARNING: Unable to verify checksum for D:\Code\electron-v1.2.6-win32-x64\node.dll
    02 000000f8`6b7eccb0 00007ff9`e9aa0468 KERNEL32!ExitProcessImplementation+0xa
    03 000000f8`6b7ecce0 00007ff9`e9aa0404 node!exit_or_terminate_process+0x48 [d:\th\minkernel\crts\ucrt\src\appcrt\startup\exit.cpp @ 129]
    04 000000f8`6b7ecd10 00007ff9`e9a87209 node!common_exit+0x150 [d:\th\minkernel\crts\ucrt\src\appcrt\startup\exit.cpp @ 269]
    05 000000f8`6b7ecd40 00007ff9`e92b1ef2 node!raise+0x165 [d:\th\minkernel\crts\ucrt\src\appcrt\misc\signal.cpp @ 463]
    06 000000f8`6b7ecdc0 00007ff9`e92bb570 node!node::cares_wrap::Initialize+0x8e [c:\jenkins\workspace\electron-win-x64\vendor\node\src\cares_wrap.cc @ 1330]
    07 000000f8`6b7ecea0 00007ff9`e9674919 node!node::Binding+0x1cc [c:\jenkins\workspace\electron-win-x64\vendor\node\src\node.cc @ 2517]
    08 000000f8`6b7edb40 00007ff9`e950a62c node!v8::internal::FunctionCallbackArguments::Call+0x99 [c:\jenkins\workspace\libchromiumcontent-win\vendor\chromium\src\v8\src\api-arguments.cc @ 17]
    
  11. meteormatt commented on Aug 22, 2016

    @meteormatt

    I face the same problem on Windows Server 2012 R2
    Node.js v6.4.0

  12. Nedgeva commented on Oct 7, 2016

    @Nedgeva

    Same here
    NodeJS v6.7.0 x64 Win7
    Node exits automatically (with "Assertion failed: (r) == (0)" error) if IP changed to local.

  13. bnoordhuis commented on Oct 7, 2016

    @bnoordhuis
    Member

    This has been fixed by #8710 and is scheduled for back-porting to the release branches.

    You still won't end up with a workable binary if the system resolver is borked but at least you get an exception that you can catch and marvel at. That is, this now works:

    try {
      var dns = require('dns');
    } catch (e) {
      console.error(e);
    }
    if (dns) {
      // ...
    }
  14. weagle08 commented on Oct 16, 2016

    @weagle08

    so does this allow me to run on a LAN network just using configured IP with no DNS set?

  15. bnoordhuis commented on Oct 16, 2016

    @bnoordhuis
    Member

    Depends on the exact configuration but probably not. See #8966 for more discussion.

  16. anaisbetts commented on Oct 16, 2016

    @anaisbetts

    @bnoordhuis Thanks for the fix and the update

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    c++Issues and PRs that require attention from people who are familiar with C++.caresIssues and PRs related to the c-ares dependency or the cares_wrap binding.dnsIssues and PRs related to the dns subsystem.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions