网络通道创建常见错误及解决方法
在使用 Hyperledger Fabric 2.5 创建网络通道时,经常会遇到Error: got unexpected status: BAD_REQUEST -- Attempted to include member Org1MSP which is not in the consortium 错误,提示成员未在联盟中。即使configtx.yaml 文件已正确定义了组织成员(例如 Org1 和 Org2),此错误仍然可能出现。 原因在于生成创世块或创建通道时使用的配置文件没有正确引用这些组织成员。
解决方法:
Profiles 部分的 TwoOrgsOrdererGenesis 和 TwoOrgsChannel 等配置文件正确引用了 Org1 和 Org2。configtx.yaml 文件中的名称完全一致,大小写也要匹配。configtx.yaml 文件中的组织设置。另一个常见错误是:error validating channel creation transaction for new channel 'mychannel', could not successfully apply update to template configuration: error authorizing update: error validating DeltaSet: policy for [Group] /Channel/Application not satisfied: implicit policy evaluation failed - 0 sub-policies were satisfied, but this policy requires 1 of the 'Admins' sub-policies to be satisfied。 此错误表示/Channel/Application 组的管理员策略未满足,通常是因为缺少有效的管理员签名或管理员策略定义错误。
解决方法:
configtx.yaml 文件中定义的管理员策略(例如 Admins 策略),确保其正确且符合组织结构。遇到 Hyperledger Fabric 问题时,建议加入相关的技术社区或论坛寻求帮助,获取更多信息和社区支持。 希望以上信息能够帮助您顺利创建 Hyperledger Fabric 2.5 网络通道。