IBM-Blockchain-Archive / marbles

WARNING: This repository is no longer maintained ⚠️ This repository will not be updated. The repository will be kept available in read-only mode.
Apache License 2.0
1.03k stars 979 forks source link

Mac OS - sudo node install_chaincode.js - gives error #168

Closed govidat closed 6 years ago

govidat commented 6 years ago

Trying to setup Marbles demo locally. Gives error in this step. It is searching for ...-priv file in main directory /Users/Govind/.hfc-key-store/. While the file is in Users/Govind/Documents/032017Official/learning/marbles/config/crypto/prebaked/...

Have already put this in my .profile as mentioned in the tutorial: export PATH=$PWD/bin:$PATH


info: Loaded config file /Users/Govind/Documents/032017Official/learning/marbles/config/marbles_local.json info: Loaded creds file /Users/Govind/Documents/032017Official/learning/marbles/config/blockchain_creds_local.json

info: Lets install some chaincode - marbles v4

info: First we enroll info: [fcw] Going to enroll with admin cert! peer_urls=[grpc://localhost:7051], channel_id=mychannel, uuid=marbles-Docker Compose Network-mychannel-fabric-peer-org1, orderer_url=grpc://localhost:7050, msp_id=Org1MSP events.js:160 throw er; // Unhandled 'error' event ^

Error: ENOENT: no such file or directory, open '/Users/Govind/.hfc-key-store/cd96d5260ad4757551ed4a5a991e62130f8008a0bf996e4e4b84cd097a747fec-priv' at Error (native)

govidat commented 6 years ago

Copied the contents of /fabcar/hfc-key-store into a newly created folder Users/Govind/.hfc-key-store. Now it works.

ishwaryaatrity commented 6 years ago

@govidat Copied the contents of /fabcar/hfc-key-store into a newly created folder Users/Govind/.hfc-key-store. Now it works.

i am not getting which folder we need to create it?

govidat commented 6 years ago

That was an earlier problem for me. Though I followed the tutorial , I got the above error message. Error message was about two files -priv and -pub not being in a specific folder. While these two files were in a subfolder in marbles/... , the message was searching in another root folder. Hence, at that time, I copied the required contents and put them in the folder, where it was searching.

I tried, the same tutorial two days back and did not get this error message.