尝试实例化composer运行时出错。错误:没有来自任何同行的有效回复。 for Multi organization hyperledger fabric 1.1

时间:2018-04-02 07:16:04

标签: hyperledger-fabric hyperledger-composer

我正在尝试在本地设置多组织的超级分层结构+编辑器设置。设置超级分类网络的步骤如下:

  

生成加密材料和通道

  • cryptogen generate --config =。/ crypto-config.yaml configtxgen -profile OrdererGenesis -outputBlock ./channel-artifacts/genesis.block
  • configtxgen -profile Channel -CreateChannelTx ./channel-artifacts/channel.tx-channelID ehrchannel
  • configtxgen -profile Channel -outputAnchorPeersUpdate ./channel-artifacts/Hospital1MSPanchors.tx-channelID ehrchannel -asOrg Hospital1MSP
  • configtxgen -profile Channel -outputAnchorPeersUpdate ./channel-artifacts/Hospital2MSPanchors.tx-channelID ehrchannel -asOrg Hospital2MSP
      

    为两个组织启动docker containors   在cli containor

    上执行以下命令
  • peer channel create -o orderer.ehr.com:7050 -c ehrchannel -f ./channel-artifacts/channel.tx --tls true --cafile /opt/gopath/src/github.com/hyperledger/fabric /peer/crypto/ordererOrganizations/ehr.com/orderers/orderer.ehr.com/msp/tlscacerts/tlsca.ehr.com-cert.pem
  

让所有对等方加入通道并设置适当的env变量     - peer channel join -b ehrchannel.block   通过设置env变量

来更新两个组织的锚点对等体
  • peer channel update -o orderer.ehr.com:7050 -c ehrchannel -f ./channel-artifacts/Hospital1MSPanchors.tx --tls true --cafile /opt/gopath/src/github.com/hyperledger/fabric /peer/crypto/ordererOrganizations/ehr.com/orderers/orderer.ehr.com/msp/tlscacerts/tlsca.ehr.com-cert.pem

之后我跟着Hyperledger composer document配置了编辑器。 但是在文档的第17步,我收到了一个错误

composer network start -c PeerAdmin@ehr-network-hos1 -a marbles-network.bna -o endorsementPolicyFile=/tmp/composer/endorsement-policy.json -A admin1 -C admin2/admin-pub.pem -A admin2 -C admin2/admin-pub.pem
Starting business network from archive: marbles-network.bna
Business network definition:
        Identifier: marbles-network@0.1.14
        Description: Marble Trading Network

Processing these Network Admins:
        userName: admin1
        userName: admin2

✖ Starting business network definition. This may take a minute...
Error: Error trying to instantiate composer runtime. Error: No valid responses from any peers.
Response from attempted peer comms was an error: Error: 2 UNKNOWN: chaincode error (status: 500, message: cannot get package for chaincode (marbles-network:0.18.2))
Response from attempted peer comms was an error: Error: 2 UNKNOWN: chaincode error (status: 500, message: cannot get package for chaincode (marbles-network:0.18.2))
Response from attempted peer comms was an error: Error: 2 UNKNOWN: chaincode error (status: 500, message: cannot get package for chaincode (marbles-network:0.18.2))
Response from attempted peer comms was an error: Error: 2 UNKNOWN: chaincode error (status: 500, message: cannot get package for chaincode (marbles-network:0.18.2))

Command failed

有哪些潜在问题?非常感谢你。

2 个答案:

答案 0 :(得分:1)

检查结构节点日志以找到线索:

docker logs [orderer/peer/...]

答案 1 :(得分:1)

您使用的是哪种版本的Composer和Fabric?如果您使用的是Composer v0.18.2,则需要使用GA版本的Fabric v1.1。

Composer的发行版文档详细介绍了Composer和Fabric的兼容版本。 https://github.com/hyperledger/composer/releases

您的命令中可能还有一个拼写错误... -A admin1 -C admin2/admin-pub.pem -A admin2 -C admin2/admin-pub.pem您是否为admin1指定了错误的文件夹?