/ usr / local / bin / node: not found

I kept getting the error above, when I do node, I got the following error:

/usr/bin/node

so in my .bash_profile, I added:

export PATH=/usr/bin:$PATH

but still the error does not disappear

+6
source share
3 answers

if you cannot or do not want to change the program you are running. (you can simply change / usr / local / bin / node to / usr / bin / node in this program), an alternative solution is to create a link from your node installation to the path that it is trying to load it.

run this as root:

ln -s /usr/bin/node /usr/local/bin/node 

This should solve the problem.

NTN bobvk

+9
source

This is completely normal, and this is not a mistake. At startup, the whichresult will be the location of the program if it was successfully installed.

+3

are you trying to run node.js ?, in ubuntu 14.04 node.js is installed in usr / bin / nodejs. Therefore, to run programs, you need to use Windows nodejs my_file.jsinstead of node node my_file.js.

You can confirm this using the command whichas above.

0
source

All Articles