[英]How to find chaincode id in fabric?
How to find chaincode id after running peer chaincode install
and peer chaincode instantiate
commands. 在运行
peer chaincode install
和peer chaincode instantiate
命令后,如何查找chaincode ID。
While running peer chaincode query
I need to pass the chaincode id. 在运行
peer chaincode query
我需要传递链码ID。 Otherwise I am getting this error in peer console: 否则我会在对等控制台中收到此错误:
ChaincodeId: test_cc does not exist on channel: testchainid(err:chaincode not found test_cc)
Usage:
peer chaincode install [flags]
Flags:
-h, --help help for install
Global Flags:
--cafile string Path to file containing PEM-encoded trusted certificate(s) for the ordering endpoint
-C, --chainID string The chain on which this command should be executed (default "testchainid")
-c, --ctor string Constructor message for the chaincode in JSON format (default "{}")
-E, --escc string The name of the endorsement system chaincode to be used for this chaincode
-l, --lang string Language the chaincode is written in (default "golang")
--logging-level string Default logging level and overrides, see core.yaml for full syntax
-n, --name string Name of the chaincode
-o, --orderer string Ordering service endpoint
-p, --path string Path to chaincode
-P, --policy string The endorsement policy associated to this chaincode
--test.coverprofile string Done (default "coverage.cov")
-t, --tid string Name of a custom ID generation algorithm (hashing and decoding) e.g. sha256base64
--tls Use TLS when communicating with the orderer endpoint
-u, --username string Username for chaincode operations when security is enabled
-v, --version string Version of the chaincode specified in install/instantiate/upgrade commands
-V, --vscc string The name of the verification system chaincode to be used for this chaincode
the -n
or --name
option that you use is the chaincode id. 您使用的
-n
或--name
选项是链码ID。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.