Hyperledger Caliper安装(最新19-12-23)

Hyperledger Caliper
官网:https://github.com/hyperledger/caliper

一、确定有没有安装这些工具

The following tools are required to install the CLI from NPM:
	1. node-gyp, python2, make, g++ and git (for fetching and compiling some packages during install)
	2. Node.js v8.X LTS or v10.X LTS (for running Caliper)
	3. Docker and Docker Compose (only needed when running local examples, or using Caliper through its Docker image)
	#建议将老版本卸载了重装node

node安装

	https://nodejs.org/dist/latest-v10.x/     #官网下载源码
	tar -xvf  node-v10.18.0-linux-x64.tar.gz
	sudo mv  node-v10.18.0-linux-x64 /usr/local/
	sudo gedit /etc/profile  (将下面环境加到末尾)
	export PATH=$PATH:/usr/local/node-v10.18.0-linux-x64/bin

二、安装caliper

1. npm init -y
2. npm install --only=prod @hyperledger/caliper-cli
3. npx caliper bind --caliper-bind-sut fabric --caliper-bind-sdk 1.4.0
4. npx caliper benchmark run --caliper-workspace . --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peergoleveldb/fabric-go.yaml

(新建一个文件夹,执行1,执行2可能会很慢,建议先换成npm淘宝源。执行完3,第4步需要样例文件,github上去下载,把他们放在一起)
淘宝源:npm config set registry http://registry.npm.taobao.org/
样例文件:https://github.com/hyperledger/caliper-benchmarks

Hyperledger Caliper安装(最新19-12-23)_第1张图片

Bingo

在这里插入图片描述
有问题,DD我。

你可能感兴趣的:(Hyperledger Caliper安装(最新19-12-23))