当我尝试通过此命令安装less: npm install less . 我收到一个错误: npm ERR! Error: EROFS, symlink '../less/bin/lessc'npm ERR! If you need help, you may report this *entire* log,npm ERR! including the npm and node versions,
npm install less .
我收到一个错误:
npm ERR! Error: EROFS, symlink '../less/bin/lessc' npm ERR! If you need help, you may report this *entire* log, npm ERR! including the npm and node versions, at: npm ERR! <http://github.com/isaacs/npm/issues> npm ERR! System Linux 3.2.0-4-amd64 npm ERR! command "/usr/local/bin/node" "/usr/local/bin/npm" "install" "less" "." npm ERR! cwd /var/www/epi npm ERR! node -v v0.10.24 npm ERR! npm -v 1.3.21 npm ERR! path ../less/bin/lessc npm ERR! code EROFS npm ERR! errno 56 npm ERR! npm ERR! Additional logging details can be found in: npm ERR! /var/www/epi/npm-debug.log npm ERR! not ok code 0
我正在使用debian wheezy,我从sources安装了节点.
尝试使用–no-bin-link标志再次运行安装.npm install --no-bin-link less .
执行正常安装时,结构如下所示:
. └── node_modules ├── .bin │ └── lessc └── less
所有–no-bin-link标志都删除了符号链接:
node_modules/.bin/lessc --> node_modules/less/bin/lessc
仍然可以使用lessc可执行文件:
. └── node_modules └── less └── bin └── lessc
以上所有想法都来自您的具体错误:
Error: EROFS, symlink
但更一般地说,EROFS错误只是意味着“错误:只读文件系统”,因此您可能只需要更改目录中正在运行install命令的权限,或者以sudo身份以root身份运行它.