Repository navigation
Description
Summary
When using nvm 0.40.3 to install node 25.0.0 or higher on recent Ubuntu images, the resulting installation fails to run any node or npm commands.
I'm not 100% sure nvm is the correct place to open this issue, from my perspective the problem can probably be solved be any of node, npm, nvm, ubuntu or the end user. I assume it is best solved by either node, npm or nvm, but since the corresponding npm issue has had no reply by the npm team I'm assuming they believe it's not their responsibility, hence me opening an issue here instead.
If you feel this issue does not belong with nvm, let me know where you believe it belongs, it's my assumption that node / npm "just working" on Ubuntu after nvm install node is desired by either node, npm or nvm.
Operating system and version:
Ubuntu. I tested 24.04, 25.10 and 26.04 and they all exhibit this behavior. The outputs in the remainder of this will be from 25.10. All tests were done using docker run -it --rm ubuntu:<version> /bin/bash.
nvm debug output:
Details
nvm --version: v0.40.3
$SHELL: /bin/bash
$SHLVL: 1
whoami: 'root'
${HOME}: /root
${NVM_DIR}: '${HOME}/.nvm'
${PATH}: ${NVM_DIR}/versions/node/v25.2.1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
$PREFIX: ''
${NPM_CONFIG_PREFIX}: ''
$NVM_NODEJS_ORG_MIRROR: ''
$NVM_IOJS_ORG_MIRROR: ''
shell version: 'GNU bash, version 5.2.37(1)-release (x86_64-pc-linux-gnu)'
uname -a: 'Linux 5.10.0-27-amd64 #1 SMP Debian 5.10.205-2 (2023-12-31) x86_64 GNU/Linux'
checksum binary: 'sha256sum'
OS version: Ubuntu 25.10
awk: /usr/bin/awk, mawk 1.3.4 20250131
curl: /usr/bin/curl, curl 8.14.1 (x86_64-pc-linux-gnu) libcurl/8.14.1 OpenSSL/3.5.3 zlib/1.3.1 brotli/1.1.0 zstd/1.5.7 libidn2/2.3.8 libpsl/0.21.2 libssh2/1.11.1 nghttp2/1.64.0 librtmp/2.3 OpenLDAP/2.6.10
wget: not found
git: not found
grep: /usr/bin/grep (grep --color=auto), grep (GNU grep) 3.11
sed: /usr/bin/sed, sed (GNU sed) 4.9
cut: /usr/bin/cut, cut (uutils coreutils) 0.2.2
basename: /usr/bin/basename, basename (uutils coreutils) 0.2.2
rm: /usr/bin/rm, rm (GNU coreutils) 9.5
mkdir: /usr/bin/mkdir, mkdir (uutils coreutils) 0.2.2
xargs: /usr/bin/xargs, xargs (GNU findutils) 4.10.0
nvm current: none
which node: ${NVM_DIR}/versions/node/v25.2.1/bin/node
which iojs:
which npm: ${NVM_DIR}/versions/node/v25.2.1/bin/npm
npm config get prefix: node: error while loading shared libraries: libatomic.so.1: cannot open shared object file: No such file or directory
npm root -g: node: error while loading shared libraries: libatomic.so.1: cannot open shared object file: No such file or directorynvm ls output:
Details
v25.2.1
default -> node (-> v25.2.1)
iojs -> N/A (default)
unstable -> N/A (default)
node -> stable (-> v25.2.1) (default)
stable -> 25.2 (-> v25.2.1) (default)
lts/* -> lts/krypton (-> N/A)
lts/argon -> v4.9.1 (-> N/A)
lts/boron -> v6.17.1 (-> N/A)
lts/carbon -> v8.17.0 (-> N/A)
lts/dubnium -> v10.24.1 (-> N/A)
lts/erbium -> v12.22.12 (-> N/A)
lts/fermium -> v14.21.3 (-> N/A)
lts/gallium -> v16.20.2 (-> N/A)
lts/hydrogen -> v18.20.8 (-> N/A)
lts/iron -> v20.19.5 (-> N/A)
lts/jod -> v22.21.1 (-> N/A)
lts/krypton -> v24.11.1 (-> N/A)How did you install nvm?
Following the (as of 18.11.25) current installation instructions in the readme of this repository:
apt-get update && apt-get -y install curlcurl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.3/install.sh | bashexport NVM_DIR="$([ -z "${XDG_CONFIG_HOME-}" ] && printf %s "${HOME}/.nvm" || printf %s "${XDG_CONFIG_HOME}/nvm")"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"What steps did you perform?
- Installed nvm following the steps above
- Installed node 25.0.0 (or 25.1.0, 25.2.1) using
nvm install 25.0.0 - Ran
node --version(ornpm --version)
What happened?
Steps 1 & 2 seemed to complete successfully
Step 3 printed "node: error while loading shared libraries: libatomic.so.1: cannot open shared object file: No such file or directory"
What did you expect to happen?
I expected it to print the node/npm version. More specifically, I expected any node/npm command to work and all required system dependencies to be installed.
Is there anything in any of your profile files that modifies the PATH?
I don't believe so. I've used unmodified ubuntu images from the docker registry for reproduction, unless these come with the PATH pre-modified.
Activity
[-]nvm-installed npm fails all commands on ubuntu due to missing lib[/-][+]nvm-installed node/npm fails all commands on ubuntu due to missing lib[/+]shawnnolanjr commentedon Nov 18, 2025
today all of a sudden i wasn't able to use nestjs commands, and i'm not sure if this is the place either, but after trying to reinstall nvm i get
1dEraNCeSIv0 commentedon Nov 18, 2025
Seems like a different issue, downloading and installing nvm works without problems for me.
ljharb commentedon Nov 19, 2025
That is an issue with node, specifically, not npm or nvm, so node would be the place to file it.
1dEraNCeSIv0 commentedon Nov 19, 2025
Thanks for the fast response, will do.
shawnnolanjr commentedon Nov 19, 2025
I didn't realize that 20% of the internet was down at the time of writing, that was the issue.