Hyperledger fabric - 无法将对等连接到通道 - 背书客户端无法连接 - 连接被拒绝

Hyperledger fabric - Cant connect peer to channel - endorser client failed to connect - connection refused

我创建了一个测试频道并尝试使用下面的代码加入对等点。

export CORE_PEER_LOCALMSPID="Org1MSP"
export CORE_PEER_TLS_ROOTCERT_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/peers/peer1.org1.example.com/tls/ca.crt
export CORE_PEER_MSPCONFIGPATH=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/users/Admin@org1.example.com/msp
export CORE_PEER_ADDRESS=peer1.org1.example.com:7051

peer channel join -b testchannel.block

但是出现如下连接错误

Error: error getting endorser client for channel: endorser client failed to connect to peer1.org1.example.com:7051: failed to create new connection: connection error: desc = "transport: error while dialing: dial tcp 172.18.0.3:7051: connect: connection refused"

我尝试了其他类似帖子中提到的解决方案,例如更改 CORE_PEER_TLS_ENABLED 但它仍然发生。如何解决?谢谢!

您需要检查 docker 对等点的日志

docker logs <container id>

所提供的信息不足以帮助您。