gpt4 book ai didi

docker - 在Fabric第一网络示例中,热修复错误: “transport: error while dialing: dial tcp: lookup peer0.org1.example.com: no such host”

转载 作者:行者123 更新时间:2023-12-02 18:47:54 29 4
gpt4 key购买 nike

无法运行结构第一个网络示例

这是我运行时的日志:./byfn up


/ ___| |_ _| / \ | _ \ |_ _|
\___ \ | | / _ \ | |_) | | |
___) | | | / ___ \ | _ < | |
|____/ |_| /_/ \_\ |_| \_\ |_|

Build your first network (BYFN) end-to-end test

Channel name : mychannel
Creating channel...
+ peer channel create -o orderer.example.com:7050 -c mychannel -f ./channel-artifacts/channel.tx --tls true --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
+ res=0
+ set +x
2019-06-27 22:22:11.117 UTC [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
2019-06-27 22:22:12.361 UTC [cli.common] readBlock -> INFO 002 Received block: 0
===================== Channel 'mychannel' created =====================

Having all peers join the channel...
+ peer channel join -b mychannel.block
+ res=1
+ set +x
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: lookup peer0.org1.example.com: no such host"
peer0.org1 failed to join the channel, Retry after 9 seconds

我的环境:
Ubuntu 18.04
Docker version 18.06.1-ce, build e68fc7a
docker-compose version 1.24.0, build 0aa59064
go version go1.11.11 linux/amd64

echo $GOPATH results in /usr/local/go/bin

同行应该能够加入该 channel

最佳答案

尝试在 peer-base.yaml 文件的环境部分添加- GODEBUG=netdns=go,可以在 fabric-samples / first-newtork / base / 中找到它

这是一个众所周知的问题
简而言之,这是由于文件resolv.conf的更改引起的,Hyperledger Fabric中的容器间域名解析已从纯Go解析器切换到cgo解析器,由已知静态链接cgo引起的SIGSEGV错误被触发,因此Hyperledger Fabric部署失败。
要了解更多信息,请遵循link

关于docker - 在Fabric第一网络示例中,热修复错误: “transport: error while dialing: dial tcp: lookup peer0.org1.example.com: no such host”,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56799114/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com