Installation error: EACCES: permission denied
See original GitHub issuelorien@air:/web/token_qwerty$ sudo npm install --save -g solgraph
npm WARN deprecated babel-preset-es2015@6.24.1: π Thanks for using Babel: we recommend using babel-preset-env now: please read babeljs.io/env to update!
npm WARN deprecated jade@0.26.3: Jade has been renamed to pug, please install the latest version of pug instead of jade
npm WARN deprecated to-iso-string@0.0.2: to-iso-string has been deprecated, use @segment/to-iso-string instead.
npm WARN deprecated minimatch@0.3.0: Please update to minimatch 3.0.2 or higher to avoid a RegExp DoS issue
/usr/bin/solgraph -> /usr/lib/node_modules/solgraph/solgraph.js
> solgraph@0.2.6 postinstall /usr/lib/node_modules/solgraph
> npm run build
npm ERR! path /root/.npm/_logs
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall scandir
npm ERR! Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm ERR! { Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm ERR! stack: 'Error: EACCES: permission denied, scandir \'/root/.npm/_logs\'',
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'scandir',
npm ERR! path: '/root/.npm/_logs' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.
glob error { Error: EACCES: permission denied, scandir '/root/.npm/_logs'
stack: 'Error: EACCES: permission denied, scandir \'/root/.npm/_logs\'',
errno: -13,
code: 'EACCES',
syscall: 'scandir',
path: '/root/.npm/_logs' }
> solgraph@0.2.6 build /usr/lib/node_modules/solgraph
> babel -d dist src
Error: EACCES: permission denied, mkdir '/usr/lib/node_modules/solgraph/dist'
at Object.fs.mkdirSync (fs.js:892:18)
at sync (/usr/lib/node_modules/solgraph/node_modules/mkdirp/index.js:71:13)
at outputFileSync (/usr/lib/node_modules/solgraph/node_modules/output-file-sync/index.js:44:24)
at write (/usr/lib/node_modules/solgraph/node_modules/babel-cli/lib/babel/dir.js:33:5)
at handleFile (/usr/lib/node_modules/solgraph/node_modules/babel-cli/lib/babel/dir.js:43:7)
at /usr/lib/node_modules/solgraph/node_modules/babel-cli/lib/babel/dir.js:61:9
at Array.forEach (<anonymous>)
at handle (/usr/lib/node_modules/solgraph/node_modules/babel-cli/lib/babel/dir.js:59:29)
at Array.forEach (<anonymous>)
at module.exports (/usr/lib/node_modules/solgraph/node_modules/babel-cli/lib/babel/dir.js:69:15)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! solgraph@0.2.6 build: `babel -d dist src`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the solgraph@0.2.6 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
βββββββββββββββββββββββββββββββββββββββββββββββββββββ
β npm update check failed β
β Try running with sudo or get access β
β to the local update config store via β
β sudo chown -R $USER:$(id -gn $USER) /root/.config β
βββββββββββββββββββββββββββββββββββββββββββββββββββββ
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.1.2 (node_modules/solgraph/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! code ELIFECYCLE
npm ERR! errno 243
npm ERR! solgraph@0.2.6 postinstall: `npm run build`
npm ERR! Exit status 243
npm ERR!
npm ERR! Failed at the solgraph@0.2.6 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2017-10-08T02_05_08_724Z-debug.log
npm: 5.3.0 node: 8.6.0 os: debian stretch
Content of /root/.npm/_logs/2017-10-08T02_05_08_724Z-debug.log attached. 2017-10-08T02_05_08_724Z-debug.log
Issue Analytics
- State:
- Created 6 years ago
- Reactions:5
- Comments:5
Top Results From Across the Web
Error: EACCES: permission denied - node.js - Stack Overflow
This command fix the issue. It worked for me: sudo npm install -g --unsafe-perm=true --allow-root.
Read more >Resolving EACCES permissions errors when installing ...
Resolving EACCES permissions errors when installing packages globally Β· Reinstall npm with a node version manager Β· Manually change npm's default directory.
Read more >Error: EACCES: permission denied with npm - How to fix
1. Reinstalling npm with a node version manager. To publish and install packages to and from the public npm registry we must install...
Read more >Fix NPM EACCES permission denied errors ... - YouTube
How to fix eacces permission denied errors with npm when installing a global package using Ubuntu. An easy fix is to install using...
Read more >NPM Install - Resolving EACCES Permissions Denied
How to resolve eacces permissions denied when installing npm packages globally. Here's how you solve this issue in a couple of minutes.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
This worked for me:
@d0o0 I just used your approach and npm install --save -g solgraph worked. Thanks