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 install grpc@1.10.1 ERR #136

Closed
llhl001 opened this issue Jul 18, 2018 · 6 comments
Closed

npm install grpc@1.10.1 ERR #136

llhl001 opened this issue Jul 18, 2018 · 6 comments

Comments

@llhl001
Copy link

llhl001 commented Jul 18, 2018

`
[root@llhl178 caliper]# npm install grpc@1.10.1
npm WARN registry Unexpected warning for https://registry.npmjs.org/: Miscellaneous Warning ECONNREFUSED: request to https://registry.npmjs.org/decamelize failed, reason: connect ECONNREFUSED 104.18.96.96:443
npm WARN registry Using stale package data from https://registry.npmjs.org/ due to a request error during revalidation.

grpc@1.10.1 install /opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc
node-pre-gyp install --fallback-to-build --library=static_library

node-pre-gyp ERR! Pre-built binaries not installable for grpc@1.10.1 and node@8.11.3 (node-v57 ABI, glibc) (falling back to source compile with node-gyp)
node-pre-gyp ERR! Hit error EACCES: permission denied, mkdir '/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/src/node'
gyp ERR! configure error
gyp ERR! stack Error: EACCES: permission denied, mkdir '/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/build'
gyp ERR! System Linux 4.17.6-1.el7.elrepo.x86_64
gyp ERR! command "/usr/local/node-v8.11.3-linux-x64/bin/node" "/usr/local/node-v8.11.3-linux-x64/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "configure" "--fallback-to-build" "--library=static_library" "--module=/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/src/node/extension_binary/node-v57-linux-x64-glibc/grpc_node.node" "--module_name=grpc_node" "--module_path=/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/src/node/extension_binary/node-v57-linux-x64-glibc"
gyp ERR! cwd /opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc
gyp ERR! node -v v8.11.3
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
node-pre-gyp ERR! build error
node-pre-gyp ERR! stack Error: Failed to execute '/usr/local/node-v8.11.3-linux-x64/bin/node /usr/local/node-v8.11.3-linux-x64/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --library=static_library --module=/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/src/node/extension_binary/node-v57-linux-x64-glibc/grpc_node.node --module_name=grpc_node --module_path=/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/src/node/extension_binary/node-v57-linux-x64-glibc' (1)
node-pre-gyp ERR! stack at ChildProcess. (/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/node_modules/node-pre-gyp/lib/util/compile.js:83:29)
node-pre-gyp ERR! stack at emitTwo (events.js:126:13)
node-pre-gyp ERR! stack at ChildProcess.emit (events.js:214:7)
node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:925:16)
node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
node-pre-gyp ERR! System Linux 4.17.6-1.el7.elrepo.x86_64
node-pre-gyp ERR! command "/usr/local/node-v8.11.3-linux-x64/bin/node" "/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" "--library=static_library"
node-pre-gyp ERR! cwd /opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc
node-pre-gyp ERR! node -v v8.11.3
node-pre-gyp ERR! node-pre-gyp -v v0.7.0
node-pre-gyp ERR! not ok
Failed to execute '/usr/local/node-v8.11.3-linux-x64/bin/node /usr/local/node-v8.11.3-linux-x64/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js configure --fallback-to-build --library=static_library --module=/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/src/node/extension_binary/node-v57-linux-x64-glibc/grpc_node.node --module_name=grpc_node --module_path=/opt/gopath/src/github.com/hyperledger/caliper/node_modules/grpc/src/node/extension_binary/node-v57-linux-x64-glibc' (1)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! grpc@1.10.1 install: node-pre-gyp install --fallback-to-build --library=static_library
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the grpc@1.10.1 install 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/2018-07-18T03_01_41_563Z-debug.log
`

@bitpeng
Copy link
Contributor

bitpeng commented Jul 18, 2018

@gongchuanhua try to run : npm i grpc@1.10.1 --unsafe-perm

@aklenik
Copy link
Contributor

aklenik commented Oct 10, 2018

@gongchuanhua My experience is that it's simpler to install local packages as a non-root user. Way less headache (and no need for root privileges anyway):

git clone https://github.com/hyperledger/caliper.git
cd caliper
npm install
npm install grpc@1.10.1 fabric-ca-client@1.1.0 fabric-client@1.1.0

@llhl001
Copy link
Author

llhl001 commented Oct 10, 2018

thanks ,It Works!

@ishandutta2007
Copy link

I needed to downgrade node from 10.12 to 8.11

node -v

v10.12.0

npm install -g n
n 8.11.1
mode -v

v8.11.1

@Hdezhkam
Copy link

npm install firebase --force

@aklenik
Copy link
Contributor

aklenik commented Feb 28, 2020

For anyone struggling with global installs or grpc/node versions, check out the Dockerfile for Caliper for the non-root global install approach: https://github.com/hyperledger/caliper/blob/master/packages/caliper-publish/caliper.Dockerfile

For installing on node 10.x LTS, check out the binding file for the necessary environment and install settings: https://github.com/hyperledger/caliper/blob/master/packages/caliper-cli/lib/lib/config.yaml#L18

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

5 participants