【发布时间】:2020-02-09 02:36:08
【问题描述】:
我正在搭建一个由两个组织组成的服务器(后面是3个),如下链接所示:https://hyperledger-fabric.readthedocs.io/en/release-1.4/network/network.html
但是,联盟不能包含两个组织(Org1 和 Org2),而只能包含组织 1 (Org1),如下图所示:https://imgur.com/a/gcBcINq
在我的 configtx.yaml 文件中,我将 SampleConsortium 值设置如下:
Profiles:
TwoOrgsOrdererGenesis:
<<: *ChannelDefaults
Orderer:
<<: *OrdererDefaults
Organizations:
- *OrdererOrg
Capabilities:
<<: *OrdererCapabilities
Consortiums:
SampleConsortium:
Organizations:
- *Org1
# - *Org2
TwoOrgsChannel:
Consortium: SampleConsortium
<<: *ChannelDefaults
Application:
<<: *ApplicationDefaults
Organizations:
- *Org1
- *Org2
Capabilities:
<<: *ApplicationCapabilities
所以我定义了一个具有单一组织的联盟:Org2。
但是,当使用代码行实例化我的频道时
peer channel create -o orderer.example.com:7050 -c $CHANNEL_NAME -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
屏幕显示一个错误告诉我:错误:出现意外状态:BAD_REQUEST -- 尝试包含一个不在联盟中的成员
您是否有想法通过在我的联盟中只有一个组织来生成我的频道?
非常感谢您的回答:)
PS:这是我第一个使用超级账本结构的项目,所以我对这项技术仍然“新”。但是,在我看来,没有迹象表明一个财团不应拥有至少 2 个组织。
【问题讨论】:
-
从 TwoOrgschannel 配置文件中删除 Org2 详细信息
标签: hyperledger-fabric blockchain hyperledger