I have just installed nodejs on a new EC2 micro instance. I installed it normally, ./configure -> make -> sudo make install. Problem: When I run "node" under ec2-user, it runs perfectly. When I run "sudo node", it fails. I found out that node is in: [ec2-user@XXXX ~]$ whereis node node: /usr/local/bin/node /usr/local/lib/node and the current path is [ec2-user@XXXX ~]$ echo $PATH /usr/local/bin:/bi
![On EC2: sudo node command not found, but node without sudo is ok](https://cdn-ak-scissors.b.st-hatena.com/image/square/98d6f053a97a87156775f60757c60865d0f2c47d/height=288;version=1;width=512/https%3A%2F%2Fcdn.sstatic.net%2FSites%2Fstackoverflow%2FImg%2Fapple-touch-icon%402.png%3Fv%3D73d79a89bded)