【发布时间】:2023-04-03 09:51:01
【问题描述】:
来自fabric document create-join-channel,当我执行命令时
peer channel create -o orderer.example.com:7050 -c $CHANNEL_NAME -f ./channel-artifacts/channel.tx --tls $CORE_PEER_TLS_ENABLED --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
它返回错误sn-p以下消息:
2017-08-16 01:34:13.902 UTC [msp] GetLocalMSP -> DEBU 00c 返回现有的本地 MSP 2017-08-16 01:34:13.902 UTC [msp] GetDefaultSigningIdentity -> DEBU 00d 获取默认签名身份 2017-08-16 01:34:13.902 UTC [msp/identity] 符号 -> DEBU 00e 符号:明文:0AC3060A1508021A060895C2CECC0522...7E2E59E3CFD14AC765C92FBF36614E79 2017-08-16 01:34:13.902 UTC [msp/identity] 符号 -> DEBU 00f 符号:摘要:FA75790826EF23E1A7C46AD3B9AE0DB7321DC271B8BE93A29BAC2F6EEACBB8B0 错误:出现意外状态:BAD_REQUEST 用法: 对等通道创建 [标志]
标志:
命令如下:
cryptogen generate --config=./crypto-config.yaml
export FABRIC_CFG_PATH=$PWD
configtxgen -profile TwoOrgsOrdererGenesis -outputBlock ./channel-artifacts/genesis.block
export CHANNEL_NAME=mychannel
configtxgen -profile TwoOrgsChannel -outputCreateChannelTx ./channel-artifacts/channel.tx -channelID $CHANNEL_NAME
configtxgen -profile TwoOrgsChannel -outputAnchorPeersUpdate ./channel-artifacts/Org1MSPanchors.tx -channelID $CHANNEL_NAME -asOrg Org1MSP
configtxgen -profile TwoOrgsChannel -outputAnchorPeersUpdate ./channel-artifacts/Org2MSPanchors.tx -channelID $CHANNEL_NAME -asOrg Org2MSP
CHANNEL_NAME=$CHANNEL_NAME TIMEOUT=10000 docker-compose -f docker-compose-cli.yaml up -d
docker exec -it cli bash
export CHANNEL_NAME=mychannel
peer channel create -o orderer.example.com:7050 -c $CHANNEL_NAME -f ./channel-artifacts/channel.tx --tls $CORE_PEER_TLS_ENABLED --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
【问题讨论】:
-
能否删除所有容器并再次运行?!您是否正在执行“./byfn.sh -m up”命令?如果您手动生成工件,则不得执行“./byfn.sh -m up”命令。
标签: hyperledger hyperledger-fabric