Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NodeJS installation giving "curl: (92) HTTP/2 stream 1 was not closed cleanly: INTERNAL_ERROR (err 2)" when running from fixed IP address multiple times #3074

Open
aristeia opened this issue Mar 30, 2023 · 2 comments
Labels
feature requests I want a new feature in nvm! installing node Issues with installing node/io.js versions.

Comments

@aristeia
Copy link

Operating system and version:

Multiple AWS Services (like AWS Device Farm and AWS Code Deploy) which use hosts that exist in a highly-limited IP space

What steps did you perform?

nvm install some_version_number

What happened?

In a small percentage of cases, the download of Node from nodejs.org slows to a crawl before failing. The AWS service teams believe the root cause to be throttling from nodejs.org against the highly-limited IP space used by the hosts running the NVM installation commands.

Exact output:

nvm install 14.17.1
...
############                                                              17.8%
##############                                                            19.5%curl: (92) HTTP/2 stream 0 was not closed cleanly: INTERNAL_ERROR (err 2)

What did you expect to happen?

nvm install should install the version of node. A reasonable mitigation for this type of problem would be to have the download command (https://github.com/nvm-sh/nvm/blob/master/nvm.sh#L124) use exponential backoffs (https://everything.curl.dev/usingcurl/downloads/retry). Can this be made into a feature-flag (or default behavior) of NVM?

@ljharb
Copy link
Member

ljharb commented Mar 30, 2023

I don’t think that’s worth adding into nvm itself, considering you can run nvm install yourself inside such a loop. It’s very rare to have network issues, and it usually coincides with releases going out.

If this is a common problem with a specific vendor, then AWS (or yourself) could easily set up its own nodejs.org mirror, and use the env var to point nvm at it.

@ljharb ljharb added installing node Issues with installing node/io.js versions. feature requests I want a new feature in nvm! labels Mar 30, 2023
@5cript
Copy link

5cript commented Oct 25, 2023

I also ran into this issue from within official azure pipeline service runners.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature requests I want a new feature in nvm! installing node Issues with installing node/io.js versions.
Projects
None yet
Development

No branches or pull requests

3 participants