fabric 国密版本改造

~、设计

SM国密依赖库选型。   自研 ;第3方库测试评估

docker镜像生成和测试。  生产数据导入实测、观察。    

 

~、确认下列问题(fabric-1.4.1-gm)

开发途中,重新启动1次kafka后,kafka 连接报错:Rejecting deliver request because of consenter error。

         链码调用报错 : Error sending transaction invoke: Got unexpected status: SERVICE_UNAVAILABLE。

~、fabric-1.4.1-gm  国密版本改造       @Ubu1604    Z470

报错 :找不到加密依赖包 golang.org/x/crypto/chacha20poly1305

处理 :下载 https://github.com/golang/crypto 替换 vendor/golang.org/x/crypto

~、注意,国密版本与非国密版混搭开发时

在同一台机器上(Z470本+Ubu1604),国密版本与非国密版混搭开发时,注意两个不同版本的Orderer启动顺序。

fabric-1.4.1-gm版本若先启动,不会pacnic ; 

若先启动原始非国密版的fabric-1.4.1,事后即使关闭并退出了fabric-1.4.1,接着又启动fabric-1.4.1-gm(国密版本 ),会出现pacnic 。

 

// 另,Kafka 重置处理,否则还会看到旧通道如"ka1",似乎删不掉它们(Orderer服务,在"ORDERER_FILELEDGER_LOCATION"指示的路径下)。

//清除用户旧数据,除了把orderer、peer生成的目录删除,莫忘重置Kafka,再重启kafka_2.11-1.0.1,及若干个order + peer。

 

API server listening at: 127.0.0.1:2345

2019-08-30 13:52:28.058 CST [localconfig] completeInitialization -> INFO 001 Kafka.Version unset, setting to 0.10.2.0

bccsp gm keyimport pk is *sm2.PublicKeybccsp gm keyimport pk is *sm2.PublicKeybccsp gm keyimport pk is *sm2.PublicKeySM3

2019-08-30 13:52:28.086 CST [orderer.common.server] prettyPrintStruct -> INFO 002 Orderer config values:

 

          ...  ...     ...  ...     

bccsp gm keyimport pk is *sm2.PublicKeybccsp gm keyimport pk is *sm2.PublicKeySM3

bccsp gm keyimport pk is *sm2.PublicKeybccsp gm keyimport pk is *sm2.PublicKeySM3

bccsp gm keyimport pk is *sm2.PublicKeybccsp gm keyimport pk is *sm2.PublicKeySM3

2019-08-30 13:52:30.430 CST [orderer.consensus.kafka] processMessagesToBlocks -> WARN 015 [channel: testchainid] Error when processing incoming message of type REGULAR = discarding bad config message because = error validating channel creation transaction for new channel'ka1', could not succesfully apply update to template configuration: error authorizing update: error validating DeltaSet: invalid mod_policy for element [Policy] /Channel/Application/Admins: mod_policy not set

bccsp gm keyimport pk is *sm2.PublicKey

panic: interface conversion: interface {} is *sm2.PublicKey, not *ecdsa.PublicKey

~、kafka 重置  @ubu1604     //删除旧数据,全新投入使用:不重启机器,只需重启kafka

退出 kafka_2.11-1.0.1: pkill -f zookeeper & pkill -f -9 kafka 

删除以下三个目录。  /tmp :kafka-logs    zookeeper    hsperfdata_chenlx  

你可能感兴趣的:(软件产品开发)