EExcel 丞燕快速查詢2

EExcel 丞燕快速查詢2
EExcel 丞燕快速查詢2 https://sandk.ffbizs.com/

[DIY] HyperLedger

1. Use docker-machine crate docker vm.

And install docker-compose.

2. https://github.com/hyperledger/fabric-samples



# Fetch bootstrap.sh from fabric repository using
curl -sS https://raw.githubusercontent.com/hyperledger/fabric/master/scripts/bootstrap.sh -o ./scripts/bootstrap.sh

# Change file mode to executable
chmod +x ./scripts/bootstrap.sh

# Download binaries and docker images
#./scripts/bootstrap.sh [version] [ca version] [thirdparty_version]

./scripts/bootstrap.sh

Here use all default value.


3. https://hyperledger-fabric.readthedocs.io/en/latest/build_network.html


# Start Run

cd fabric-samples/first-network  
./byfn.sh generate
./byfn.sh up

4. Hope you see

===================== Query successful on peer1.org2 on channel 'mychannel' =====================

========= All GOOD, BYFN execution completed ===========

5. check docker ps Need like this




PS:


1. See Error

2019-11-06 02:22:34.819 UTC [main] InitCmd -> ERRO 001 Cannot run peer because cannot init crypto, folder "/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/users/Admin@org1.example.com/msp" does not exist
!!!!!!!!!!!!!!! Channel creation failed !!!!!!!!!!!!!!!!
========= ERROR !!! FAILED to execute End-2-End Scenario ===========

How to Fix


cd fabric-samples/first-network  
./byfn.sh down
./byfn.sh generate  #This maybe don't need
./byfn.sh up


6. How to querying chaincode again

https://learnblockchain.cn/2019/07/03/chaincode-run/


docker exec -it cli bash

root@73e65944cade:/opt/gopath/src/github.com/hyperledger/fabric/peer>


root@73e65944cade:/opt/gopath/src/github.com/hyperledger/fabric/peer>  peer chaincode query -C mychannel -n mycc -c '{"Args":["query","a"]}'

# peer chaincode query This command come from e2etest that you first time See This message:
========= All GOOD, BYFN execution completed =========== 
Then just find screen up, can see "peer chaincode query ooxxooxxooxx". Please copy it then use in here.