When I console in my ubuntu platform I am getting the following to check the node details.

here is the ouput:

dev@ubuntu14044:~$ nodejs -v
dev@ubuntu14044:~$ node -v
dev@ubuntu14044:~$ npm -v

to upgrade my nodejs - I tried like this: sudo apt-get install -y nodejs But allways I am getting the nodejs version as v0.10.25 But I want to update that in to latest as 7.x how to do that?


The packaged nodejs installs version 0.10.25

You'll have to remove it first

sudo apt-get purge nodejs*

Then as mentioned on node.js website, setup a ppa & then install

curl -sL https://deb.nodesource.com/setup_7.x | sudo -E bash -
sudo apt-get install -y nodejs
  • If I run all commands you given, I am getting this error : ## Confirming "n/a" is supported... + curl -sLf -o /dev/null 'https://deb.nodesource.com/node_7.x/dists/n/a/Release' ## Your distribution, identified as "n/a", is not currently supported, please contact NodeSource at https://github.com/nodesource/distributions/issues if you think this is incorrect or would like your distribution to be considered for support - how to fix this? – 3gwebtrain Apr 11 '17 at 7:03
  • what distro are you using – Sathyajith Bhat Apr 11 '17 at 13:27
  • I am not getting you.. distro stands for? – 3gwebtrain Apr 12 '17 at 6:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.