Darshan
Darshan

Reputation: 23

Endorser client failed to connect : connection refused Error

I want to set up a Hyperledger fabric network on the Aws server, the network is working in my local system but on the AWS server I am getting below error while starting Hyperleger fabric network.

Error: error getting endorser client for channel: endorser client failed to connect to peer0.org1.example.com:7051: failed to create new connection: connection error: desc = "transport: error while dialing: dial tcp 172.28.0.9:7051: connect: connection refused"
peer0.org1 failed to join the channel, Retry after 3 seconds

version:

 1. Hyperledger Version: 1.4.6 
 2. Go version: go1.12.12
 3. OS/Arch:linux/amd64
 4. Chaincode:   Base Image Version: 0.4.18 

while up the first network, by using the below command:

./byfn.sh up -a -s couchdb

Please help me on how to resolve the above issues.

Upvotes: 2

Views: 2947

Answers (2)

Nithin TD
Nithin TD

Reputation: 90

This issue is related to TLS, you need to disable the TLS in peer-base.yaml and docker-compose-cli.yaml and run the network

CORE_PEER_TLS_ENABLED=false

ORDERER_GENERAL_TLS_ENABLED=false

and also you need to change grpcs to grpc inside the network configuration files

and also don't use the peer and orderer TLS certificate file while deploying chaincode

Upvotes: 5

Shubham Jaiswal
Shubham Jaiswal

Reputation: 610

The issue what I see is , you have enabled the TLS in your network and not providing the TLS cert files in the connection profile. If encrypting the communication between peers and orderers is not priority for you right now then you can disable it in your docker file.

CORE_PEER_TLS_ENABLED=false

or you can also enable the TLS in your network like this example and it comes mandatory if you are using RAFT ordering service. https://github.com/IBM/raft-fabric-sample

Upvotes: 0

Related Questions