How to set-up distributed system of peer nodes in different machines in hyperledger-fabric v1.0.0 beta ?
Asked
Active
Viewed 2,099 times
1
-
Here is the script https://github.com/yacovm/fabricDeployment allowing to setup and configure distributed Hyperledger Fabric setup for multiple nodes. – Artem Barger Jul 01 '17 at 09:06
-
Hi subhra were you able to complete your setup? – Katiyman Aug 28 '17 at 05:08
-
No I was not able to do so – Subhra Mazumdar Aug 28 '17 at 19:20
1 Answers
2
First of all, you should define how is going to be your network, i.e. how many and wich nodes are going to be started up in each machine. Then, you should define the docker-compose files for each machine. There you define the nodes that you will put up in each machine.
At the end, you will start up the nodes.
Make sure that you define well the configuration of all the config files, especially the hosts.

Urko
- 1,479
- 1
- 14
- 20
-
So for 3 machines we will have 3 local docker compose file ? Can you send an example as in how you had implemented it ? How do these nodes connect to one channel ? Is it that from each machine we will have to create a cli container ? – Subhra Mazumdar Jun 30 '17 at 11:14
-
I copy & paste the configuration file that you have in the docker-compose-cli.yaml file and the base/docker-compose-base.yaml file. I deleted the service and containers that I don't need in each machine. Then, you connect to the channel: 1) Via the definition of the Peers in the configtx.ymal; 2) Creating the channel; 3) At the end, each Peer joins the channel – Urko Jul 03 '17 at 11:33
-
Its not working since two network needs to be joined based on some common network. I tried that using docker swarm but the network driver is being reset to the default one . How to change that ? How did you set up the network without docker swarm ? – Subhra Mazumdar Jul 04 '17 at 03:12
-
You have to comment the default network (byfn), and add a new property for each container: network_mode: host. Also, in the peer-base.yaml file, you should change the CORE_VM_DOCKER_HOSTCONFIG_NETWORKMODE=host. I need to read more about Docker ant its networks, I'm new on it. Probably it would be better if you used docker-machine. – Urko Jul 06 '17 at 14:32
-
-
i am getting grpc: addrConn.resetTransport failed to create client transport: connection error: desc = "transport: Error while dialing dial tcp: lookup orderer.example.com on 127.0.1.1:53: no such host"; Reconnecting to {orderer.example.com:7050
} – Abdul Wahab Jan 10 '18 at 06:00 -
1Can your hosts communicate among them? Could you try to do a ping among then? Probably, you have to change your docker configuration. You can read more about it here: https://stackoverflow.com/questions/44775844/error-starting-up-a-network-nodes-in-different-vm-failed-connecting-to-ordere – Urko Jan 10 '18 at 11:19