修改/etc/profile文件,在末尾添加以下内容 export NODE_HOME=/usr/local/node # Node所在路径 export PATH=$NODE_HOME/bin:$PATH