"/usr/bin/env: ‘node’: No such file or directory" even though it is in PATH
By Gabriel Cooper •
I'm trying to get nodejs working. However, it tells me that node is not in my bin even though I downloaded the binary and added the location to my path.
> echo $PATH
...:/home/jvdh/node-v8.11.2-linux-x64/bin
>sudo npm install -g bitcore/usr/bin/env: ‘node’: No such file or directory
3 Answers
Install nodejs8
curl -sL | sudo -E bash -
sudo apt-get install -y nodejsInstall nodejs10
curl -sL | sudo -E bash -
sudo apt-get install -y nodejsThen try again with node
3Usually this is a simple naming problem, when you install from a package manager your bin file may be called nodejs so you just need to symlink it using the command:
ln -s /usr/bin/nodejs /usr/bin/node
For Ubuntu 20.04, you can install node.js and npm:
sudo apt install nodejs npm