0

After installing node.js on a playground raspberry pi, i'm able to run node.js scripts.

Now i had a folder which a packages.config which contains a dependency to express.js

when running

npm install

i see that the packages are downloaded. but later on the procesessing failes due to write problems.

on the folder i've set some time ago

chmod 0777

I also have to mention that i copied the node.js application folder from a windows pc via samba to this public shared folder

Also clearing the npm cache didn't help

what am i doing wrong?

here the output when i type npm install express

npm WARN package.json SerialReader@0.0.0 No repository field.
npm http GET https://registry.npmjs.org/express
npm http 200 https://registry.npmjs.org/express
npm http GET https://registry.npmjs.org/express/-/express-4.11.0.tgz
npm http 200 https://registry.npmjs.org/express/-/express-4.11.0.tgz
npm ERR! error rolling back Error: EACCES, unlink '/be/Serial/node_modules/express'
npm ERR! error rolling back  express@4.11.0 { [Error: EACCES, unlink '/be/Serial/node_modules/express']
npm ERR! error rolling back   errno: 3,
npm ERR! error rolling back   code: 'EACCES',
npm ERR! error rolling back   path: '/be/Serial/node_modules/express' }
npm ERR! Error: EACCES, unlink '/be/Serial/node_modules/express'
npm ERR!  { [Error: EACCES, unlink '/be/Serial/node_modules/express']
npm ERR!   errno: 3,
npm ERR!   code: 'EACCES',
npm ERR!   path: '/be/Serial/node_modules/express' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! System Linux 3.12.35+
npm ERR! command "/opt/node-v0.10.28-linux-arm-pi/bin/node" "/opt/node-v0.10.28-linux-arm-pi/bin/npm" "install" "express"
npm ERR! cwd /be/Serial
npm ERR! node -v v0.10.28
npm ERR! npm -v 1.4.9
npm ERR! path /be/Serial/node_modules/express
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, unlink '/be/Serial/node_modules/express'
npm ERR! Error: EACCES, open 'npm-debug.log'
npm ERR!  { [Error: EACCES, open 'npm-debug.log'] errno: 3, code: 'EACCES', path: 'npm-debug.log' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! System Linux 3.12.35+
npm ERR! command "/opt/node-v0.10.28-linux-arm-pi/bin/node" "/opt/node-v0.10.28-linux-arm-pi/bin/npm" "install" "express"
npm ERR! cwd /be/Serial
npm ERR! node -v v0.10.28
npm ERR! npm -v 1.4.9
npm ERR! path npm-debug.log
npm ERR! code EACCES
npm ERR! errno 3
npm ERR! stack Error: EACCES, open 'npm-debug.log'
npm ERR!
npm ERR! Additional logging details can be found in:
npm ERR!     /be/Serial/npm-debug.log
npm ERR! not ok code 0
  • Have you tried running this with sudo? – Steve Robillard Jan 20 '15 at 8:26
  • Yeah unfortunately i got another problem with that. see raspberrypi.stackexchange.com/questions/26966/… but nevertheless i would really like to understand why this doesn't work. npm should have write permissions to this folder, shouldn't it ? – Boas Enkler Jan 20 '15 at 8:53
  • 3
    Exactly what error message do you get? – Bex Jan 20 '15 at 8:54
  • I added the output to the post – Boas Enkler Jan 20 '15 at 18:19

Your Answer

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

Browse other questions tagged or ask your own question.