./byfn.sh -m up -c imooc 运行成功,但容器cli运行一下就闪退报错
来源:2-4 fabric尝鲜

CaesarVong
2020-06-12
老师,你好。./byfn.sh -m up运行成功后,所有新建的容器都能够正常运行,但cli突然就会闪退,我试了很多次都存在这种现象。然后我单独启动cli报错信息如下:
/ __| | | / \ | _ \ | _|
___ \ | | / _ \ | |_) | | |
___) | | | / ___ \ | _ < | |
|/ || // _\ || _\ ||
Build your first network (BYFN) end-to-end test
Channel name : imocc
Creating channel…
CORE_PEER_TLS_ROOTCERT_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/tls/ca.crt
CORE_PEER_TLS_KEY_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/tls/server.key
CORE_PEER_LOCALMSPID=Org1MSP
CORE_VM_ENDPOINT=unix:///host/var/run/docker.sock
CORE_PEER_TLS_CERT_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/tls/server.crt
CORE_PEER_TLS_ENABLED=true
CORE_PEER_MSPCONFIGPATH=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/users/Admin@org1.example.com/msp
CORE_PEER_ID=cli
CORE_LOGGING_LEVEL=DEBUG
CORE_PEER_ADDRESS=peer0.org1.example.com:7051
2020-06-12 11:55:13.311 UTC [msp] GetLocalMSP -> DEBU 001 Returning existing local MSP
2020-06-12 11:55:13.312 UTC [msp] GetDefaultSigningIdentity -> DEBU 002 Obtaining default signing identity
2020-06-12 11:55:13.316 UTC [channelCmd] InitCmdFactory -> INFO 003 Endorser and orderer connections initialized
2020-06-12 11:55:13.318 UTC [msp] GetLocalMSP -> DEBU 004 Returning existing local MSP
2020-06-12 11:55:13.318 UTC [msp] GetDefaultSigningIdentity -> DEBU 005 Obtaining default signing identity
2020-06-12 11:55:13.318 UTC [msp] GetLocalMSP -> DEBU 006 Returning existing local MSP
2020-06-12 11:55:13.318 UTC [msp] GetDefaultSigningIdentity -> DEBU 007 Obtaining default signing identity
2020-06-12 11:55:13.319 UTC [msp/identity] Sign -> DEBU 008 Sign: plaintext: 0A8C060A074F7267314D53501280062D…53616D706C65436F6E736F727469756D
2020-06-12 11:55:13.319 UTC [msp/identity] Sign -> DEBU 009 Sign: digest: F0CACAEB29D18D0DB98103F3515A8843A163C8E147B865B1809AC745487B0B3A
2020-06-12 11:55:13.319 UTC [msp] GetLocalMSP -> DEBU 00a Returning existing local MSP
2020-06-12 11:55:13.319 UTC [msp] GetDefaultSigningIdentity -> DEBU 00b Obtaining default signing identity
2020-06-12 11:55:13.319 UTC [msp] GetLocalMSP -> DEBU 00c Returning existing local MSP
2020-06-12 11:55:13.319 UTC [msp] GetDefaultSigningIdentity -> DEBU 00d Obtaining default signing identity
2020-06-12 11:55:13.319 UTC [msp/identity] Sign -> DEBU 00e Sign: plaintext: 0ABF060A1108021A0608A1DA8DF70522…4A6C47667B0E50523EEB998B9A4E045C
2020-06-12 11:55:13.319 UTC [msp/identity] Sign -> DEBU 00f Sign: digest: E0B81A51DF3E9F849BC08A35645C4B8129D46E8F407268D636963B99C50CC43A
Error: Got unexpected status: BAD_REQUEST
Usage:
peer channel create [flags]
Flags:
-c, --channelID string In case of a newChain command, the channel ID to create.
-f, --file string Configuration transaction file generated by a tool such as configtxgen for submitting to orderer
-t, --timeout int Channel creation timeout (default 5)
Global Flags:
–cafile string Path to file containing PEM-encoded trusted certificate(s) for the ordering endpoint
–logging-level string Default logging level and overrides, see core.yaml for full syntax
-o, --orderer string Ordering service endpoint
–test.coverprofile string Done (default “coverage.cov”)
–tls Use TLS when communicating with the orderer endpoint
-v, --version Display current version of fabric peer server
!!! Channel creation failed !!!
========= ERROR !!! FAILED to execute End-2-End Scenario ===========
1回答
-
CaesarVong
提问者
2020-06-12
peer channel create -o orderer.example.com:7050 -c imocc -f ./channel-artifacts/channel.tx --tls --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
具体应该是这段代码运行报的错,但原因还不清楚。
00
相似问题