newonexd / newonexd.github.io

0 stars 0 forks source link

深入解析Hyperledger Fabric搭建的全过程 ~ 任晓东的博客 #10

Open newonexd opened 4 years ago

newonexd commented 4 years ago

https://newonexd.github.io/2019/11/23/blog/fabric/%E6%B7%B1%E5%85%A5%E8%A7%A3%E6%9E%90Fabric%E6%90%AD%E5%BB%BA%E7%9A%84%E5%85%A8%E8%BF%87%E7%A8%8B/

a495257982 commented 4 years ago

楼主 peer channel update -o orderer.example.com:7050 -c mychannel -f ./channel-artifacts/Org2MSPanchors.tx --tls true --cafile $ORDERER_CA 执行这一句报错 BAD_REQUEST -- error applying config update to existing channel 'mychannel': error authorizing update: error validating DeltaSet: policy for [Group] /Channel/Application/Org2MSP not satisfied: signature set did not satisfy policy

ghost commented 4 years ago

我也出现了这个错误

ghost commented 4 years ago

@a495257982 楼主 peer channel update -o orderer.example.com:7050 -c mychannel -f ./channel-artifacts/Org2MSPanchors.tx --tls true --cafile $ORDERER_CA 执行这一句报错 BAD_REQUEST -- error applying config update to existing channel 'mychannel': error authorizing update: error validating DeltaSet: policy for [Group] /Channel/Application/Org2MSP not satisfied: signature set did not satisfy policy

newonexd commented 4 years ago

@576498007 @a495257982 CORE_PEER_LOCALMSPID="Org2MSP" CORE_PEER_TLS_ROOTCERT_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org2.example.com/peers/peer0.org2.example.com/tls/ca.crt CORE_PEER_MSPCONFIGPATH=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org2.example.com/users/Admin@org2.example.com/msp CORE_PEER_ADDRESS=peer0.org2.example.com:9051 更新组织二的锚节点之前需要配置一下环境变量,之前忘记添加上了

a495257982 commented 4 years ago

peer chaincode invoke -o orderer.example.com:7050 --tls true --cafile $ORDERER_CA -C mychannel -n mycc -c '{"Args":["invoke","a","b","10"]}'

执行这个转账的时候报错说chainid没有参数 he required parameter 'channelID' is empty. Rerun the command with -C flag 怎么解决

ghost commented 4 years ago

不好意思,这个问题我想了很长时间也没有解决,但是为了学习进度我就直接往下进行了。

------------------ 原始邮件 ------------------ 发件人: "a495257982"<notifications@github.com>; 发送时间: 2020年4月27日(星期一) 下午4:20 收件人: "newonexd/newonexd.github.io"<newonexd.github.io@noreply.github.com>; 抄送: "M"<576498007@qq.com>; "Mention"<mention@noreply.github.com>; 主题: Re: [newonexd/newonexd.github.io] 深入解析Hyperledger Fabric搭建的全过程 ~ 任晓东的博客 (#10)

peer chaincode invoke -o orderer.example.com:7050 --tls true --cafile $ORDERER_CA -C mychannel -n mycc -c '{"Args":["invoke","a","b","10"]}'

执行这个转账的时候报错说chainid没有参数 he required parameter 'channelID' is empty. Rerun the command with -C flag 怎么解决

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.

hehui0316 commented 4 years ago

CORE_PEER_LOCALMSPID="Org2MSP" CORE_PEER_TLS_ROOTCERT_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org2.example.com/peers/peer0.org2.example.com/tls/ca.crt CORE_PEER_MSPCONFIGPATH=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org2.example.com/users/Admin@org2.example.com/msp CORE_PEER_ADDRESS=peer0.org2.example.com:9051 更新组织二的锚节点之前需要配置一下环境变量,之前忘记添加上了 请问怎么配置环境变量

hehui0316 commented 4 years ago

=========peer1.org1=========== 注意这里端口要与上面文件中配置的端口号相同

q请问这里的配置文件是指什么?

hehui0316 commented 4 years ago

因为当前cli容器使用的是peer0的配置,所以可以直接将peer0加入通道

peer channel join -b channel-artifacts/mychannel.block

更新环境变量使其他节点也加入通道

=========peer1.org1=========== 注意这里端口要与上面文件中配置的端口号相同

CORE_PEER_ADDRESS=peer1.org1.example.com:8051

=========peer0.org2============

CORE_PEER_LOCALMSPID="Org2MSP" CORE_PEER_TLS_ROOTCERT_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org2.example.com/peers/peer0.org2.example.com/tls/ca.crt CORE_PEER_MSPCONFIGPATH=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org2.example.com/users/Admin@org2.example.com/msp CORE_PEER_ADDRESS=peer0.org2.example.com:9051 peer channel join -b channel-artifacts/mychannel.block

出现Error: error getting endorser client for channel: endorser client failed to connect to peer0.org2.example.com:9051: failed to create new connection: context deadline exceeded

请问怎么解决

newonexd commented 4 years ago

docker-compose-base.yaml文件

hehui0316 commented 4 years ago

@newonexd

docker-compose-base.yaml文件

你前面没有提到有这个文件呀,这个文件在哪呀

newonexd commented 4 years ago

看文章开头

YL-Aaron commented 4 years ago

3.4中的安装链码,最后一句 :这一步执行完毕后可以在其他节点上也安装链码,具体环境变量配置见本文中4.2 这个在哪

newonexd commented 4 years ago

写错了,是3.2

YL-Aaron commented 4 years ago

3.2中的 CORE_PEER_ADDRESS=peer1.org1.example.com:8051 下面是不是少了一句peer channel join -b channel-artifacts/mychannel.block

YL-Aaron commented 4 years ago

不然3.5中的登陆peer1.org1节点进行查询会报错

newonexd commented 4 years ago

不然3.5中的登陆peer1.org1节点进行查询会报错

恩,是我的疏忽,加上就好了