镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

node.exe 8.7.0 and above does not work in Windows NanoServer container #16603

Description

@StefanScherer

I have problems running the newer versions of Node 8 in a Windows Nanoserver Container:

  • Version:
    8.7.0, 8.8.0, 8.8.1

  • Platform:
    Windows

  • Subsystem:
    Windows Nanoserver Container running in Windows 10 / Windows Server 2016

To reproduce the problem, just download the node.exe of specific versions in a Windows NanoServer container:

PS C:\> docker run -it microsoft/nanoserver powershell

Then inside the container:

PS C:\> $ProgressPreference = 'SilentlyContinue'
PS C:\> iwr -useb https://nodejs.org/dist/v6.11.5/win-x64/node.exe -outfile node-6.11.5.exe
PS C:\> .\node-6.11.5.exe --version
v6.11.5
PS C:\> iwr -useb https://nodejs.org/dist/v8.6.0/win-x64/node.exe -outfile node-8.6.0.exe
PS C:\> .\node-8.6.0.exe --version
v8.6.0

Beginning with Node 8.7.0 this stops working:

PS C:\> iwr -useb https://nodejs.org/dist/v8.7.0/win-x64/node.exe -outfile node-8.7.0.exe
PS C:\> .\node-8.7.0.exe --version
PS C:\> 
PS C:\> iwr -useb https://nodejs.org/dist/v8.8.0/win-x64/node.exe -outfile node-8.8.0.exe
PS C:\> .\node-8.8.0.exe --version
PS C:\> 
PS C:\> iwr -useb https://nodejs.org/dist/v8.8.1/win-x64/node.exe -outfile node-8.8.1.exe
PS C:\> .\node-8.8.1.exe --version
PS C:\> 

Activity

  1. added
    windowsIssues and PRs related to the Windows platform.
    on Oct 30, 2017
  2. maclover7 commented on Oct 30, 2017

    @maclover7
    Contributor

    cc @nodejs/platform-windows

  3. StefanScherer commented on Oct 30, 2017

    @StefanScherer
    Author

    Just tested the binaries in Windows Server 1709 images (microsoft/windowsservercore:1709 and microsoft/nanoserver:1709) and all versions 8.7.0, 8.8.0 and 8.8.1 work there.
    I have to check my older Windows Server 2016 setup again why it didn't work multiple times.

  4. StefanScherer commented on Oct 30, 2017

    @StefanScherer
    Author

    OK, I ran another test on a fresh Window Server 2016 in Azure, tested with several microsoft/nanoserver:10.0.14393.1066 .. microsoft/nanoserver:10.0.14393.1770 (latest) and I can reproduce the problem. Node.exe 8.7.0 ... 8.8.1 don't work in nanoserver images for the LTS channel of Windows Server 2016.

    It seems that the newer images for the Semi-annual channel of Windows Server 1709 don't have this problem.

  5. self-assigned this
    on Oct 30, 2017
  6. refack commented on Oct 30, 2017

    @refack
    Contributor

    Ohh boy. This is not going to be fun to debug 🤦‍♂️
    @StefanScherer thank you for the detailed information though 👍 Do you by any chance know where we can find something changelog like between 1770 and 1790?

  7. StefanScherer commented on Oct 30, 2017

    @StefanScherer
    Author

    @refack Oh the diff between 10.0.14393.1770 and 10.0.16299.19 = current release of Windows Server 1709 could be a little longer :-) It's not just 20 releases I guess.

  8. refack commented on Oct 30, 2017

    @refack
    Contributor

    @StefanScherer so it might be easier to figure this out from node's side (although I already have an obvious suspect, the bump in libuv from 1.14.1 to 1.15.0 https://github.com/libuv/libuv/blob/v1.x/ChangeLog)

  9. refack commented on Oct 30, 2017

    @refack
    Contributor

    P.S. node exits with 0xC0000139 {Entry Point Not Found} so it seems like we started using a new API that doesn't exists in 10.0.14393.1770

  10. refack commented on Oct 30, 2017

    @refack
    Contributor

    API diff:
    new

    AcquireSRWLockExclusive,-,-,-,kernel32.dll
    DebugBreak,x,-,-,kernel32.dll
    DispatchMessageA,x,-,-,user32.dll
    GetMessageA,-,-,-,user32.dll
    InitializeConditionVariable,-,-,-,kernel32.dll
    ReleaseSRWLockExclusive,-,-,-,kernel32.dll
    SetWinEventHook,x,-,-,user32.dll
    SleepConditionVariableSRW,-,-,-,kernel32.dll
    TranslateMessage,-,-,-,user32.dll
    WakeAllConditionVariable,-,-,-,kernel32.dll
    WakeConditionVariable,-,-,-,kernel32.dll
    

    dropped:

    VirtualProtect,x,-,-,kernel32.dll
    
  11. refack commented on Oct 30, 2017

    @refack
    Contributor

    Most probably SetWinEventHook

  12. StefanScherer commented on Oct 30, 2017

    @StefanScherer
    Author

    @refack I also tried older nanoserver:10.0.14393.x images and it's the same there.

    But with that list of API changes in Node.js maybe @PatrickLang can have a short look ^^ and give us a hint which might cause problems?

  13. StefanScherer commented on Oct 31, 2017

    @StefanScherer
    Author

    Hm, I remember the NanoServer API scan tool. Oh I still have a Docker image of that.

    FROM stefanscherer/nanoserverapiscan:onbuild
    ADD https://nodejs.org/dist/v8.6.0/win-x64/node.exe node-8.6.0.exe
    ADD https://nodejs.org/dist/v8.8.1/win-x64/node.exe node-8.8.1.exe
    docker build -t scan .
    docker run scan
    

    But it doesn't show any errors.

  14. digitalinfinity commented on Oct 31, 2017

    @digitalinfinity
    Contributor

    If @refack's assessment is correct, it's likely from libuv/libuv#1408 (since 8.7 upgraded libuv to 1.15.0)- @bzoz can you take a look, we likely need to GetProcAddress of SetWinEventHook rather than statically linking against it if the API is not present Windows NanoServer

  15. 16 remaining items

  16. reopened this on Nov 3, 2017
  17. gibfahn commented on Nov 3, 2017

    @gibfahn
    Member

    Reopening because the issue isn't fixed till this patch lands in v8.x and v6.x.

    libuv 1.15.0 is slated to land on v6.x on tuesday. Should we back it out or float this patch?

    sorry for my ignorance but that is not yet landed (to be backed out) right?

    @MylesBorins meant either back out libuv 1.15.0, or float this patch

    Not sure if possible, but if libuv could include that patch in a 1.15.1, that would be better than than floating a patch.

    I'd rather we float the patch than revert libuv 1.15.0 if possible.

  18. MylesBorins commented on Nov 3, 2017

    @MylesBorins
    Contributor

    cherry-pick in #16724

  19. refack commented on Nov 5, 2017

    @refack
    Contributor

    Good job everyone 🥇 7 days from report to fix, including a roundtrip through libuv.

  20. StefanScherer commented on Nov 6, 2017

    @StefanScherer
    Author

    I want to thank you all involved resolving this so quickly. Can‘t wait for the next release.

  21. removed their assignment
    on Oct 12, 2018
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

    windowsIssues and PRs related to the Windows platform.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions