Jeong
Jeong

Reputation: 39

Hyperledger Composer setting up connection.json

Hi thank you for all guys watching this article.

Cuz I want to use Hyperledger composer, I deployed orderer, peer, ca and other things. And I got success until creating channel and joining channel (I believe that this is true cuz I finished making channels, joining peers to join that channel, installing and instantiating chaincode.)

So after that I did

"composer network install" command and I got error that there is no response from peers. (And "Response from attempted peer comms was an error: Error: 14 UNAVAILABLE: EOF") So I started to think that there is a problem on the file named "connection.json". But I don't know specifically how to edit that file.

I got response like below commanding "docker service ls" and "docker network inspect fabric"

enter image description here

and my connection.json file looks like this

enter image description here

And I referred to this page to do Hyperledger Fabric on multiple hosts.

https://medium.com/@malliksarvepalli/hyperledger-fabric-on-multiple-hosts-using-docker-swarm-and-compose-f4b70c64fa7d

And this is the screenshot after installing business network

enter image description here

Upvotes: 2

Views: 632

Answers (2)

harry
harry

Reputation: 240

Could you confirm that all orderer, peers and CAs are successfully launched on each machine? 'docker ps' command shows which services are running. If you use 'docker ps -a', you can find which service is stopped.


From the all of docker-compose files, following container name should be listed by 'docker ps'

orderer
: orderer

org1
: ca1
: org1peer0
: org1peer1
: org1cli

org2
: ca2
: org2peer0
: org2peer1
: org2cli

Could you check this is correct?

Are you running this project on 3 machines or 3 cloud instances?

Upvotes: 2

Mahesh Rajput
Mahesh Rajput

Reputation: 276

I think your fabric network is not running!

open a terminal and go to your fabric-dev-servers directory and ./startFabric.sh

if you facing any error there, like some container already exists do ./teardownFabric.sh first and then run above start command again.

once a network is running successfully then you need to create admin card by running ./createPeerAdminCard.sh

Upvotes: 2

Related Questions