ashwanihlf / sample_3PeerNetwork

Hyperledger Fabric network with 3 Peer and 1 Orderer
0 stars 1 forks source link

Stuck at step 10 #3

Open chetanambi opened 2 years ago

chetanambi commented 2 years ago

Hi Ashwani,

I am able to run steps 1- 9 successfully. But for step 10, I am running into the below error. Can you please take a look and suggest.

[ec2-user@ip-172-31-26-189 sample_3PeerNetwork]$ docker exec -it cli /bin/bash
root@16195a277566:/opt/gopath/src/github.com/hyperledger/fabric/peer# peer chaincode invoke -C mychannel -n samplecc -c '{"function":"initCar","Args":["Ashwani","Blue","BMW"]}'
Error: error getting channel (mychannel) orderer endpoint: error bad proposal response 500: access denied for [GetConfigBlock][mychannel]: Failed to get policy manager for channel [mychannel]
root@16195a277566:/opt/gopath/src/github.com/hyperledger/fabric/peer#

Here is the console o/p after running ./start.sh

[ec2-user@ip-172-31-26-189 sample_3PeerNetwork]$ ./start.sh

# don't rewrite paths for Windows Git Bash users
export MSYS_NO_PATHCONV=1

docker-compose -f docker-compose.yml down
Removing network net_basic
WARNING: Network net_basic not found.

docker-compose -f docker-compose.yml up -d orderer.example.com peer0.org1.example.com peer0.org2.example.com peer0.org3.example.com cli
Creating network "net_basic" with the default driver
Creating orderer.example.com ... done
Creating peer0.org1.example.com ... done
Creating peer0.org3.example.com ... done
Creating peer0.org2.example.com ... done
Creating cli                    ... done
docker ps -a
CONTAINER ID   IMAGE                        COMMAND                  CREATED         STATUS                     PORTS                                                                                  NAMES
e9747b121a16   hyperledger/fabric-tools     "/bin/bash -c './scr…"   1 second ago    Up Less than a second                                                                                             cli
f4b75921b57e   hyperledger/fabric-peer      "peer node start"        3 seconds ago   Up 1 second                0.0.0.0:8051->7051/tcp, :::8051->7051/tcp, 0.0.0.0:8053->7053/tcp, :::8053->7053/tcp   peer0.org2.example.com
07bd93b25019   hyperledger/fabric-peer      "peer node start"        3 seconds ago   Up 1 second                0.0.0.0:9051->7051/tcp, :::9051->7051/tcp, 0.0.0.0:9053->7053/tcp, :::9053->7053/tcp   peer0.org3.example.com
17d942f74f7f   hyperledger/fabric-peer      "peer node start"        3 seconds ago   Up 1 second                0.0.0.0:7051->7051/tcp, :::7051->7051/tcp, 0.0.0.0:7053->7053/tcp, :::7053->7053/tcp   peer0.org1.example.com
9ecaaa4d1e28   hyperledger/fabric-orderer   "orderer"                4 seconds ago   Exited (2) 2 seconds ago                                                                                          orderer.example.com

# wait for Hyperledger Fabric to start
# incase of errors when running later commands, issue export FABRIC_START_TIMEOUT=<larger number>
export FABRIC_START_TIMEOUT=10
#echo ${FABRIC_START_TIMEOUT}
sleep ${FABRIC_START_TIMEOUT}

Thanks, Chetan

ashwanihlf commented 2 years ago

Hi Chetan

Which version of HF are you using?

Thanks

Sent from my iPhone

On 01-Feb-2022, at 4:07 PM, Chetan Ambi @.***> wrote:

 Hi Ashwani,

I am able to run steps 1- 9 successfully. But for step 10, I am running into the below error. Can you please take a look and suggest.

@. sample_3PeerNetwork]$ docker exec -it cli /bin/bash @.:/opt/gopath/src/github.com/hyperledger/fabric/peer# peer chaincode invoke -C mychannel -n samplecc -c '{"function":"initCar","Args":["Ashwani","Blue","BMW"]}' Error: error getting channel (mychannel) orderer endpoint: error bad proposal response 500: access denied for [GetConfigBlock][mychannel]: Failed to get policy manager for channel [mychannel] @.***:/opt/gopath/src/github.com/hyperledger/fabric/peer# Thanks, Chetan

— Reply to this email directly, view it on GitHub, or unsubscribe. Triage notifications on the go with GitHub Mobile for iOS or Android. You are receiving this because you are subscribed to this thread.

chetanambi commented 2 years ago

I am using the same version that is suggested in your book. I think 1.4.