Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

npm run setup error #265

Open
kcprom opened this issue Mar 4, 2022 · 2 comments
Open

npm run setup error #265

kcprom opened this issue Mar 4, 2022 · 2 comments

Comments

@kcprom
Copy link

kcprom commented Mar 4, 2022

I had a working instance of assistant-relay v3 working for nearly two years that stopped working on my Raspberry Pi 4
I updated Raspian Buster and reinstalled node.js and npm using nvm as research indicated that could solve the "EACCES: permission denied" error that appears below. Those resolution steps have not been successful. As such I am reaching out for help. Here are my software versions:

node -v = 10.24.0
pm2 -v = 5.2
npm -v = 6.14.11
python -V = 2.7.16
python3 -V = 3.7.3

Below is copy of the commands issued and the results.


pi@raspberrypi:~/Assistant-Relay $ sudo npm run setup

assistant-relay@3.3.2 setup
npm i -g pm2 && npm i

glob error [Error: EACCES: permission denied, scandir '/root/.npm/_logs'] {
errno: -13,
code: 'EACCES',
syscall: 'scandir',
path: '/root/.npm/_logs'
}
npm WARN logfile Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm WARN logfile error cleaning log files [Error: EACCES: permission denied, scandir '/root/.npm/_logs'] {
npm WARN logfile errno: -13,
npm WARN logfile code: 'EACCES',
npm WARN logfile syscall: 'scandir',
npm WARN logfile path: '/root/.npm/_logs'
npm WARN logfile }
npm ERR! code EACCES
npm ERR! syscall mkdir
npm ERR! path /root/.npm/_cacache/tmp
npm ERR! errno EACCES
npm ERR!
npm ERR! Your cache folder contains root-owned files, due to a bug in
npm ERR! previous versions of npm which has since been addressed.
npm ERR!
npm ERR! To permanently fix this problem, please run:
npm ERR! sudo chown -R 1000:1000 "/root/.npm"

npm ERR! A complete log of this run can be found in:
pi@raspberrypi:/Assistant-Relay $ sudo chown -R 1000:1000 "/root/.npm"
pi@raspberrypi:
/Assistant-Relay $ sudo npm run setup

assistant-relay@3.3.2 setup
npm i -g pm2 && npm i

glob error [Error: EACCES: permission denied, scandir '/root/.npm/_logs'] {
errno: -13,
code: 'EACCES',
syscall: 'scandir',
path: '/root/.npm/_logs'
}
npm WARN logfile Error: EACCES: permission denied, scandir '/root/.npm/_logs'
npm WARN logfile error cleaning log files [Error: EACCES: permission denied, scandir '/root/.npm/_logs'] {
npm WARN logfile errno: -13,
npm WARN logfile code: 'EACCES',
npm WARN logfile syscall: 'scandir',
npm WARN logfile path: '/root/.npm/_logs'
npm WARN logfile }
npm ERR! code EACCES
npm ERR! syscall mkdir
npm ERR! path /root/.npm/_cacache/tmp
npm ERR! errno EACCES
npm ERR!
npm ERR! Your cache folder contains root-owned files, due to a bug in
npm ERR! previous versions of npm which has since been addressed.
npm ERR!
npm ERR! To permanently fix this problem, please run:
npm ERR! sudo chown -R 1000:1000 "/root/.npm"

npm ERR! A complete log of this run can be found in:
pi@raspberrypi:~/Assistant-Relay $

@kcprom kcprom changed the title npm run setup error #264 npm run setup error Mar 4, 2022
@pierrotori
Copy link

any news ?

@greghesp
Copy link
Owner

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants