gpt4 book ai didi

docker - 开发人员Cli错误终端3的Chaincode

转载 作者:行者123 更新时间:2023-12-02 19:35:26 24 4
gpt4 key购买 nike

我正在尝试使用开发人员教程“http://hyperledger-fabric.readthedocs.io/en/latest/chaincode4ade.html”的链代码来部署链代码。我能够完成直到终端2的步骤,但是在终端3的命令“docker exec -it cli bash”中遇到错误。

端子1的输出

[]Received message REGISTER from shim peer | 2017-08-22 23:29:26.025 UTC [chaincode] HandleMessage -> DEBU 1a9 []Fabric side Handling ChaincodeMessage of type: REGISTER in state created peer | 2017-08-22 23:29:26.025 UTC [chaincode] beforeRegisterEvent -> DEBU 1aa Received REGISTER in state created peer | 2017-08-22 23:29:26.025 UTC [chaincode] registerHandler -> DEBU 1ab registered handler complete for chaincode mycc:0 peer | 2017-08-22 23:29:26.025 UTC [chaincode] beforeRegisterEvent -> DEBU 1ac Got REGISTER for chaincodeID = name:"mycc:0" , sending back REGISTERED peer | 2017-08-22 23:29:26.025 UTC [chaincode] notifyDuringStartup -> DEBU 1ad nothing to notify (dev mode ?) peer | 2017-08-22 23:29:26.025 UTC [chaincode] notifyDuringStartup -> DEBU 1ae sending READY peer | 2017-08-22 23:29:26.025 UTC [chaincode] processStream -> DEBU 1af []Move state message READY peer | 2017-08-22 23:29:26.025 UTC [chaincode] HandleMessage -> DEBU 1b0 []Fabric side Handling ChaincodeMessage of type: READY in state established peer | 2017-08-22 23:29:26.026 UTC [chaincode] enterReadyState -> DEBU 1b1 []Entered state ready peer | 2017-08-22 23:29:26.026 UTC [chaincode] notify -> DEBU 1b2 notifier Txid: does not exist peer | 2017-08-22 23:29:26.026 UTC [chaincode] processStream -> DEBU 1b3 []sending state message READY



端子2的输出:

CORE_PEER_ADDRESS=peer:7051 CORE_CHAINCODE_ID_NAME=mycc:0 ./sacc 2017-08-22 23:29:26.020 UTC [shim] SetupChaincodeLogging -> INFO 001 Chaincode log level not provided; defaulting to: INFO 2017-08-22 23:29:26.020 UTC [shim] SetupChaincodeLogging -> INFO 002 Chaincode (build level: ) starting up ...



端子3的输出

docker exec -it cli bash Error response from daemon: Container 37efeab8d4930060c9de46d3bab9ab1ab034781be26b4a5176b80b54d6c1180b is not running



我找不到任何解决方案。谁能帮我?我正在使用MacOSX。

我取消了yaml文件中的“命令:/ bin / bash -c'./script.sh'”行的注释。

终端1之后的docker ps输出:

docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES befcf58f4b59 hyperledger/fabric-ccenv "/bin/bash -c 'sle..." 21 seconds ago Up 20 seconds chaincode 3129dac3e13b hyperledger/fabric-peer "peer node start -..." 21 seconds ago Up 20 seconds 0.0.0.0:7051->7051/tcp, 0.0.0.0:7053->7053/tcp peer 56a92979e7cb hyperledger/fabric-orderer "orderer" 22 seconds ago Up 21 seconds 0.0.0.0:7050->7050/tcp orderer



终端2之后的docker ps输出:

docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES befcf58f4b59 hyperledger/fabric-ccenv "/bin/bash -c 'sle..." 2 minutes ago Up 2 minutes chaincode 3129dac3e13b hyperledger/fabric-peer "peer node start -..." 2 minutes ago Up 2 minutes 0.0.0.0:7051->7051/tcp, 0.0.0.0:7053->7053/tcp peer 56a92979e7cb hyperledger/fabric-orderer "orderer" 2 minutes ago Up 2 minutes 0.0.0.0:7050->7050/tcp orderer



运行.yaml文件时出现Cli错误:

Returning dummy reject all policy because Admins could not be found in /Application/Admins orderer | 2017-08-23 23:09:50.644 UTC [policies] GetPolicy -> DEBU 154 Returning policy Readers for evaluation orderer | 2017-08-23 23:09:50.644 UTC [policies] GetPolicy -> DEBU 155 Returning dummy reject all policy because Readers could not be found in /Application/Readers orderer | 2017-08-23 23:09:50.644 UTC [policies] GetPolicy -> DEBU 156 Returning policy Writers for evaluation orderer | 2017-08-23 23:09:50.645 UTC [policies] GetPolicy -> DEBU 157 Returning dummy reject all policy because Writers could not be found in /Application/Writers orderer | 2017-08-23 23:09:50.645 UTC [common/configtx] addToMap -> DEBU 158 Adding to config map: [Groups] /Channel orderer | 2017-08-23 23:09:50.645 UTC [common/configtx] addToMap -> DEBU 159 Adding to config map: [Groups] /Channel/Application orderer | 2017-08-23 23:09:50.645 UTC [common/configtx] addToMap -> DEBU 15a Adding to config map: [Groups] /Channel/Application/SampleOrg cli | Error: Got unexpected status: BAD_REQUEST orderer | 2017-08-23 23:09:50.645 UTC [common/configtx] addToMap -> DEBU 15b Adding to config map: [Values] /Channel/Consortium orderer | 2017-08-23 23:09:50.645 UTC [common/configtx] addToMap -> DEBU 15c Adding to config map: [Groups] /Channel cli | Usage: cli | peer channel create [flags] cli | cli | Flags: orderer | 2017-08-23 23:09:50.645 UTC [common/configtx] addToMap -> DEBU 15d Adding to config map: [Groups] /Channel/Application cli | -c, --channelID string In case of a newChain command, the channel ID to create. orderer | 2017-08-23 23:09:50.645 UTC [common/configtx] addToMap -> DEBU 15e Adding to config map: [Groups] /Channel/Application/SampleOrg cli | -f, --file string Configuration transaction file generated by a tool such as configtxgen for submitting to orderer orderer | 2017-08-23 23:09:50.646 UTC [common/configtx] addToMap -> DEBU 15f Adding to config map: [Policy] /Channel/Application/Admins cli | -t, --timeout int Channel creation timeout (default 5) cli | cli | Global Flags: cli | --cafile string Path to file containing PEM-encoded trusted certificate(s) for the ordering endpoint cli | --logging-level string Default logging level and overrides, see core.yaml for full syntax cli | -o, --orderer string Ordering service endpoint orderer | 2017-08-23 23:09:50.646 UTC [common/configtx] addToMap -> DEBU 160 Adding to config map: [Policy] /Channel/Application/Writers cli | --test.coverprofile string Done (default "coverage.cov") cli | --tls Use TLS when communicating with the orderer endpoint cli | -v, --version Display current version of fabric peer server cli | orderer | 2017-08-23 23:09:50.646 UTC [common/configtx] addToMap -> DEBU 161 Adding to config map: [Policy] /Channel/Application/Readers orderer | 2017-08-23 23:09:50.646 UTC [common/configtx] addToMap -> DEBU 162 Adding to config map: [Values] /Channel/Consortium orderer | 2017-08-23 23:09:50.646 UTC [orderer/common/broadcast] Handle -> WARN 163 Rejecting CONFIG_UPDATE because: Error authorizing update: Error validating DeltaSet: invalid mod_policy for element [Policy] /Channel/Application/Writers: mod_policy not set orderer | 2017-08-23 23:09:50.646 UTC [orderer/main] func1 -> DEBU 164 Closing Broadcast stream orderer | 2017-08-23 23:09:50.648 UTC [orderer/common/deliver] Handle -> WARN 165 Error reading from stream: rpc error: code = Canceled desc = context canceled orderer | 2017-08-23 23:09:50.649 UTC [orderer/main] func1 -> DEBU 166 Closing Deliver stream

最佳答案

我可以通过注释掉“fabric-samples / chaincode-docker-devmode / docker-compose-simple.yaml”文件中的“命令:/ bin / bash -c'./script.sh'”行来解决此问题。 。

关于docker - 开发人员Cli错误终端3的Chaincode,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45828567/

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