2

I just install node.js 4.4.4 from NVM on ubuntu 14.04.

npm --version give me 2.15.1

sudo npm --version give me sudo: npm: command not found

I first tried to solved my problem with that Q&A but as I installed node with NVM then node is install into ~/.nvm/ instead of the default location ...

Note whereis npm give me npm: with nothing after

EDIT

I've just read that NVM should remove sudo requirement in node process. But when I try npm install pm2 -g I receive npm ERR! Please try running this command again as root/Administrator. which doesn't make sens ...

Community
  • 1
  • 1
Alexandre SIRKO
  • 816
  • 11
  • 22
  • 1
    Try `sudo -s` before running your npm commands. – jperezov May 21 '16 at 22:01
  • I don t think its a good idea to install pm2 as root. I would not do that myself. see also http://pm2.keymetrics.io/docs/usage/startup/ –  May 22 '16 at 15:25

0 Answers0