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

Erro to install #2

Open
toshibochan opened this issue Dec 1, 2018 · 3 comments
Open

Erro to install #2

toshibochan opened this issue Dec 1, 2018 · 3 comments

Comments

@toshibochan
Copy link

I have error to install this homebridge.
sudo npm install -g https://github.com/sfeakes/homebridge-sprinklerd.git

0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/node',
1 verbose cli '/usr/bin/npm',
1 verbose cli 'install',
1 verbose cli '-g',
1 verbose cli 'https://github.com/sfeakes/homebridge-sprinklerd.git' ]
2 info using npm@6.4.1
3 info using node@v10.14.0
4 verbose npm-session 5fcbd560bf60af4e
5 silly install loadCurrentTree
6 silly install readGlobalPackageData
7 silly fetchPackageMetaData error for git+https://github.com/sfeakes/homebridge-sprinklerd.git Command failed: /usr/bin/git submodule update -q --init --recursive
7 silly fetchPackageMetaData fatal: Could not change back to '/root/.npm/_cacache/tmp/git-clone-8b6a18ea': Permission denied
8 timing stage:rollbackFailedOptional Completed in 3ms
9 timing stage:runTopLevelLifecycles Completed in 3379ms
10 verbose stack Error: Command failed: /usr/bin/git submodule update -q --init --recursive
10 verbose stack fatal: Could not change back to '/root/.npm/_cacache/tmp/git-clone-8b6a18ea': Permission denied
10 verbose stack
10 verbose stack at ChildProcess.exithandler (child_process.js:289:12)
10 verbose stack at ChildProcess.emit (events.js:182:13)
10 verbose stack at maybeClose (internal/child_process.js:962:16)
10 verbose stack at Socket.stream.socket.on (internal/child_process.js:381:11)
10 verbose stack at Socket.emit (events.js:182:13)
10 verbose stack at Pipe._handle.close (net.js:606:12)
11 verbose cwd /home/pi
12 verbose Linux 4.14.79-v7+
13 verbose argv "/usr/bin/node" "/usr/bin/npm" "install" "-g" "https://github.com/sfeakes/homebridge-sprinklerd.git"
14 verbose node v10.14.0
15 verbose npm v6.4.1
16 error code 128
17 error Command failed: /usr/bin/git submodule update -q --init --recursive
17 error fatal: Could not change back to '/root/.npm/_cacache/tmp/git-clone-8b6a18ea': Permission denied
18 verbose exit [ 1, true ]

@sfeakes
Copy link
Owner

sfeakes commented Dec 1, 2018

This looks like a permission issue. npm is notorious for spawning new shells, and when it does the permissions of the sudo are lost. Try this instead.

su   <- enter your root password
npm install -g https://github.com/sfeakes/homebridge-sprinklerd.git

@toshibochan
Copy link
Author

How to change root passwords?

@sfeakes
Copy link
Owner

sfeakes commented Jan 11, 2019

That depends on a ton of things. On a new install you can usually run ‘sudo password root’

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

2 participants