Giter VIP home page Giter VIP logo

caliper-benchmarks's Introduction

caliper-benchmarks's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

caliper-benchmarks's Issues

Ethereum 1node network config not working

When building the Docker image, the docker build process will fail because of a wrong genesis configuration:

Fatal: Failed to write genesis block: unsupported fork ordering: petersburgBlock not enabled, but istanbulBlock enabled at 0

When changing the genesis configuration to this, building proceeds, however we get an error err="invalid block 18: unknown ancestor":

{
  "config": {
    "chainId": 21194,
    "istanbulBlock": 0,
    "petersburgBlock": 0,
    "constantinopleBlock": 0,
    "byzantiumBlock": 0,
    "eip158Block": 0,
    "eip155Block": 0,
    "eip150Block": 0,
    "homesteadBlock": 0,
    "ethash": {}
  },
  "nonce": "0x0",
  "timestamp": "0x5cd09c57",
  "extraData": "0x0000000000000000000000000000000000000000000000000000000000000000",
  "gasLimit": "0x2faf080",
  "difficulty": "0x80000",
  "mixHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
  "coinbase": "0x0000000000000000000000000000000000000000",
  "alloc": {
    "c0a8e4d217eb85b812aeb1226fab6f588943c2c2": {
      "balance": "0x200000000000000000000000000000000000000000000000000000000000000"
    }
  },
  "number": "0x0",
  "gasUsed": "0x0",
  "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000"
}

Building the image suceeds instead of above mentioned error when using this config,

Generate.sh fails trying to generate for fabric 2.1.0

I have followed the tutorial to run the basic example benchmarks on fabric 2.1.0 (besides having to change a few of the commands because they were out of date.) So after installing caliper 0.3.2 I ran:

caliper bind --caliper-bind-sut fabric:2.1.0 --caliper-bind-args="-g"

And then, I went into each of the config folders under networks/fabric and ran generate.sh. After doing so, I run

caliper launch master --caliper-fabric-gateway-usegateway --caliper-workspace ~/Desktop/caliper-benchmarks --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig networks/fabric/v2/v2.1.0/2org1peergoleveldb_raft/fabric-go-tls.yaml

However after running the benchmark command the screen fills with hundreds of unable to connect errors.

I looked into the generate.sh files and realized they were getting fabric and fabric-ca versions 1.4.1, which is not what I was using. So I changed the scripts to download 2.1.0 instead. This worked for the fabric version, but I guess fabric-ca is behind as it failed to get that. I changed just fabric-ca to the latest version 1.4.8 and (probably because of the version desync) I get this error:

Error on outputChannelCreateTx: could not generate default config template: error parsing configuration: error adding policies to channel group: no policies defined

So unless I'm missing something, I can't use the fabric 2.1.0 benchmarks because the generate.sh scripts are not able to generate a channel for 2.1.0. If there's something else I need to do to make it work please let me know.

Unexpected error during benchmark execution: Caliper Benchmark HLF v1.4.1

Hi,

I was trying to run the caliper-benchmark and just immediately i have this error:

Unexpected error during benchmark execution: Error: Invalid "mychannel" channel configuration: child "chaincodes" fails because ["chaincodes" is required]. "contracts" is not allowed.

the command was:

caliper launch master \

--caliper-workspace ~/caliper-benchmarks \
--caliper-benchconfig benchmarks/samples/fabric/fabcar/config.yaml \
--caliper-networkconfig networks/fabric/v1/v1.4.1/2org1peergoleveldb/fabric-go.yaml

I couldnt find any solution.
The environmnet:
Node 8.15
npm 6.4
go 1.11
Ubuntu 18.04

any suggestions please ?

Error: Benchmark failed with error code 6

creating ethereum ... done
2020.07.06-02:29:46.188 info [caliper] [caliper-engine] Executed start command in 512.417 seconds
2020.07.06-02:29:52.450 info [caliper] [caliper-engine] Executed "init" step in 6.105 seconds
2020.07.06-02:29:52.451 info [caliper] [ethereum.js] Creating contracts...
2020.07.06-02:34:04.839 info [caliper] [ethereum.js] Deployed contract simple at 0x91496eafe3C54C48D1Add5c1Fb30655d6b76e56b
2020.07.06-02:34:04.948 info [caliper] [caliper-engine] Executed "install" step in 252.498 seconds
2020.07.06-02:34:05.024 info [caliper] [messenger.js] Creating messenger of type "process-master"
2020.07.06-02:34:05.578 info [caliper] [null-observer] Configured "null" observer
2020.07.06-02:34:05.580 error [caliper] [round-orchestrator] Round 1 configuration validation error: Missing "callback" attribute
2020.07.06-02:34:05.596 error [caliper] [caliper-engine] Error while performing "test" step: Error: Round 1 configuration validation error: Missing "callback" attribute
2020.07.06-02:34:05.596 info [caliper] [caliper-utils] Executing command: cd .; docker-compose -f networks/ethereum/1node/docker-compose.yml down
Stopping ethereum ... done
Removing ethereum ... done
Removing network 1node_default
2020.07.06-02:34:27.670 info [caliper] [caliper-engine] Executed end command in 22.074 seconds
2020.07.06-02:34:27.671 error [caliper] [cli-launch-master] Benchmark failed with error code 6
Usage:
caliper launch master --caliper-bind-sut fabric:1.4.1 [other options]

Options:
--help, -h Show usage information [boolean]
--version Show version information [boolean]
--caliper-bind-sut The name and version of the platform to bind to [string]
--caliper-bind-cwd The working directory for performing the SDK install [string]
--caliper-bind-args Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter [string]
--caliper-bind-file Yaml file to override default (supported) package versions when binding an SDK [string]

Error: Benchmark failed with error code 6
at Function.handler (/home/gaganq/Documents/caliperPractice/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/launch/lib/launchMaster.js:70:23)

Update the Docker-compse file

Since the HTTP connection has been disabled in the latest version. We have to use Websocket to connect to our SUT (Mine is Ethereum). The Docker-compose file should be modified accordingly. Take the one in Ethereum as an example

networks/ethereum/1node-clique/docker-compose.yml

version: "3"
services:
  node:
    build: .
    image: caliper-ethereum-clique
    container_name: ethereum_clique
    volumes:
      - ./keys:/root/.ethereum/keystore
    ports:
      - 8545:8545
      - 8546:8546      // add the port for websocket
    command: --unlock 0xc0A8e4D217eB85b812aeb1226fAb6F588943C2C2 --password /root/.ethereum/keystore/password --mine --minerthreads 2 --etherbase 0xc0A8e4D217eB85b812aeb1226fAb6F588943C2C2 --allow-insecure-unlock --nodiscover --gasprice 1 --ws --ws.addr 0.0.0.0 --ws.origins '*' --ws.port 8546 --ws.api admin,eth,web3,personal,miner --rpc --rpcaddr 0.0.0.0 --rpcvhosts=* --rpcapi admin,eth,miner,personal,web3
    // add the args for Websocket

error starting container: API error (500): Could not attach to network 2org1peergoleveldb_raft_default

when I start a benchmars using caliper cli 3.0 I get this error

Error while performing "install" step: Error: Invalid endorsement for fabcar@v0 in mychannel from peer0.org1.example.com: error starting container: error starting container: API error (500): Could not attach to network 2org1peergoleveldb_raft_default: rpc error: code = NotFound desc = network 2org1peergoleveldb_raft_default not found

panic: runtime error: index out of range with GO fixed-asset chaincode

I am getting error sending: chaincode stream terminated while running both range-query-pagination and rich-query-pagination.
The chaincode-container logs shows GO errors (chaincode is GO) regarding index out of range : "panic: runtime error: index out of range"
This would probably crash the chaincode which could explain the the peer logs show failed to invoke chaincode name:"fixed-asset" , error: chaincode stream terminated.
This problem is independent of the load. It always happen with the GO fixed-asset chaincode.

Fabric Go contract missing private data method

The Go chaincodes for fixed-asset and fixed-asset-base for fabric are missing the private data methods that currently exist in the nodeJS contract:

  • add
  • batch add
  • get
  • batch get

In order to benchmark these for Go, they need to be added

Bad block when building Ethereum network

I have successfully tested the Fabric sample given in the official documentation, but I ran into some problems when I tested the Ethereum sample
my steps:

  1. npx caliper bind --caliper-bind-sut ethereum:1.2.1
  2. npx caliper launch master --caliper-workspace . --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig networks/ethereum/1node/ethereum.json
    I got the following log error:
    2020.10.01-02:32:11.570 info [caliper] [cli-launch-master] Set workspace path: /home/qwe/Desktop/caliper-benchmarks
    2020.10.01-02:32:11.571 info [caliper] [cli-launch-master] Set benchmark configuration path: /home/qwe/Desktop/caliper-benchmarks/benchmarks/scenario/simple/config.yaml
    2020.10.01-02:32:11.571 info [caliper] [cli-launch-master] Set network configuration path: /home/qwe/Desktop/caliper-benchmarks/networks/ethereum/1node/ethereum.json
    2020.10.01-02:32:11.571 info [caliper] [cli-launch-master] Set SUT type: ethereum
    2020.10.01-02:32:12.132 info [caliper] [benchmark-validator] No observer specified, will default to none
    2020.10.01-02:32:12.132 info [caliper] [caliper-engine] Starting benchmark flow
    2020.10.01-02:32:12.148 info [caliper] [caliper-utils] Executing command: cd .; docker-compose -f networks/ethereum/1node/docker-compose.yml up -d && sleep 3
    Creating network "1node_default" with the default driver
    Building node
    Step 1/5 : FROM ethereum/client-go:stable
    stable: Pulling from ethereum/client-go
    Digest: sha256:8009eca8f4a768e76582a14b4cce0e2e0dd5044e5f963ed9e0e6e4ac435804dd
    Status: Downloaded newer image for ethereum/client-go:stable
    ---> a75aa12d09b8
    Step 2/5 : COPY ./data/ /root/
    ---> 8bc635f73614
    Step 3/5 : VOLUME [ "/root/.ethereum/keystore/" ]
    ---> Running in 12ff569cecf7
    Removing intermediate container 12ff569cecf7
    ---> bd5079036f5b
    Step 4/5 : RUN geth --nousb init /root/genesis.json && geth --nousb import /root/bc.dat && geth --nousb makedag 0 /root/.ethash && geth --nousb makedag 30000 /root/.ethash
    ---> Running in 9e34774e3b16
    INFO [10-01|09:32:33.711] Maximum peer count ETH=50 LES=0 total=50
    INFO [10-01|09:32:33.711] Smartcard socket not found, disabling err="stat /run/pcscd/pcscd.comm: no such file or directory"
    INFO [10-01|09:32:33.712] Set global gas cap cap=25000000
    INFO [10-01|09:32:33.712] Allocated cache and file handles database=/root/.ethereum/geth/chaindata cache=16.00MiB handles=16
    INFO [10-01|09:32:33.744] Writing custom genesis block
    INFO [10-01|09:32:33.755] Persisted trie from memory database nodes=1 size=171.00B time=9.895901ms gcnodes=0 gcsize=0.00B gctime=0s livenodes=1 livesize=0.00B
    INFO [10-01|09:32:33.755] Successfully wrote genesis state database=chaindata hash="cbc198…847427"
    INFO [10-01|09:32:33.755] Allocated cache and file handles database=/root/.ethereum/geth/lightchaindata cache=16.00MiB handles=16
    INFO [10-01|09:32:33.770] Writing custom genesis block
    INFO [10-01|09:32:33.780] Persisted trie from memory database nodes=1 size=171.00B time=9.469358ms gcnodes=0 gcsize=0.00B gctime=0s livenodes=1 livesize=0.00B
    INFO [10-01|09:32:33.780] Successfully wrote genesis state database=lightchaindata hash="cbc198…847427"
    INFO [10-01|09:32:33.831] Maximum peer count ETH=50 LES=0 total=50
    INFO [10-01|09:32:33.831] Smartcard socket not found, disabling err="stat /run/pcscd/pcscd.comm: no such file or directory"
    INFO [10-01|09:32:33.832] Set global gas cap cap=25000000
    INFO [10-01|09:32:33.832] Allocated cache and file handles database=/root/.ethereum/geth/chaindata cache=512.00MiB handles=524288
    INFO [10-01|09:32:34.944] Opened ancient database database=/root/.ethereum/geth/chaindata/ancient
    INFO [10-01|09:32:34.945] Disk storage enabled for ethash caches dir=/root/.ethereum/geth/ethash count=3
    INFO [10-01|09:32:34.945] Disk storage enabled for ethash DAGs dir=/root/.ethash count=2
    INFO [10-01|09:32:34.946] Loaded most recent local header number=0 hash="cbc198…847427" td=524288 age=1y5mo3d
    INFO [10-01|09:32:34.946] Loaded most recent local full block number=0 hash="cbc198…847427" td=524288 age=1y5mo3d
    INFO [10-01|09:32:34.947] Loaded most recent local fast block number=0 hash="cbc198…847427" td=524288 age=1y5mo3d
    INFO [10-01|09:32:34.947] Importing blockchain file=/root/bc.dat
    ERROR[10-01|09:32:34.948]
    ########## BAD BLOCK #########
    Chain config: {ChainID: 21194 Homestead: 0 DAO: DAOSupport: false EIP150: 0 EIP155: 0 EIP158: 0 Byzantium: 0 Constantinople: 0 Petersburg: 0 Istanbul: 0, Muir Glacier: , YOLO v1: , Engine: ethash}

Number: 1
Hash: 0x0f34a5d81e4a0c7a8cd84b5a96ed026086cad450b51eb425cdc0cde28e087b7d

Error: unknown ancestor
##############################

Import done in 1.756143ms.

Compactions
Level | Tables | Size(MB) | Time(sec) | Read(MB) | Write(MB)
-------+------------+---------------+---------------+---------------+---------------
0 | 1 | 0.00077 | 0.00000 | 0.00000 | 0.00000
-------+------------+---------------+---------------+---------------+---------------
Total | 1 | 0.00077 | 0.00000 | 0.00000 | 0.00000

ERROR[10-01|09:32:34.948] Import error err="invalid block 18: unknown ancestor"
INFO [10-01|09:32:34.948] Blockchain stopped
Read(MB):0.00247 Write(MB):0.00098
Object memory: 130.465 MB current, 130.363 MB peak
System memory: 335.091 MB current, 335.091 MB peak
Allocations: 0.022 million
GC pause: 244.961µs

Compacting entire database...
Compaction done in 22.560569ms.

Compactions
Level | Tables | Size(MB) | Time(sec) | Read(MB) | Write(MB)
-------+------------+---------------+---------------+---------------+---------------
1 | 1 | 0.00077 | 0.01190 | 0.00077 | 0.00077
-------+------------+---------------+---------------+---------------+---------------
Total | 1 | 0.00077 | 0.01190 | 0.00077 | 0.00077

Read(MB):0.00247 Write(MB):0.00189
invalid block 18: unknown ancestor
Service 'node' failed to build: The command '/bin/sh -c geth --nousb init /root/genesis.json && geth --nousb import /root/bc.dat && geth --nousb makedag 0 /root/.ethash && geth --nousb makedag 30000 /root/.ethash' returned a non-zero code: 1
2020.10.01-02:32:35.449 error [caliper] [caliper-utils] Unsuccessful command execution. Error code: 1. Terminating signal: null
2020.10.01-02:32:35.450 error [caliper] [caliper-engine] An error occurred while executing the start command: Error: Command failed: cd .; docker-compose -f networks/ethereum/1node/docker-compose.yml up -d && sleep 3
Creating network "1node_default" with the default driver
Building node
Service 'node' failed to build: The command '/bin/sh -c geth --nousb init /root/genesis.json && geth --nousb import /root/bc.dat && geth --nousb makedag 0 /root/.ethash && geth --nousb makedag 30000 /root/.ethash' returned a non-zero code: 1

2020.10.01-02:32:35.451 info [caliper] [caliper-engine] Executed start command in 23.303 seconds
2020.10.01-02:32:35.451 info [caliper] [caliper-utils] Executing command: cd .; docker-compose -f networks/ethereum/1node/docker-compose.yml down
Removing network 1node_default
2020.10.01-02:32:36.217 info [caliper] [caliper-engine] Executed end command in 0.766 seconds
2020.10.01-02:32:36.217 error [caliper] [cli-launch-master] Benchmark failed with error code 3
Usage:
caliper launch master --caliper-bind-sut fabric:1.4.1 [other options]

选项:
--help, -h Show usage information [布尔]
--version Show version information [布尔]
--caliper-bind-sut The name and version of the platform to bind to [字符串]
--caliper-bind-cwd The working directory for performing the SDK install [字符串]
--caliper-bind-args Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter [字符串]
--caliper-bind-file Yaml file to override default (supported) package versions when binding an SDK [字符串]

Error: Benchmark failed with error code 3
at Function.handler (/home/qwe/Desktop/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/launch/lib/launchMaster.js:70:23)
at process._tickCallback (internal/process/next_tick.js:68:7)

Add license checking to repo

The license checking mechanism present in the Caliper repo should also be added to this one, enforced by a simple Travis job.

Too many non-option arguments: got 2, maximum of 1

when after this command shows Too many non-option arguments: got 2, maximum of 1

npx caliper benchmark run --caliper-workspace ./fabric_worksapce --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig

Caliper Benchmark Ethereum: Payable functions

One of my Ethereum smart contract functions is of type payable. Thus, I need to send a certain amount of ether to the function so it executes its logic. I could not find such a field provided by your Blockchain call function blockchain.invokeSmartContract(), I also looked at caliper/packages/caliper-ethereum/lib/ethereum.js trying to find a field or function to specify but still have no clue.

Appreciate any hint or idea on what I could do to test my payable function through Caliper.

Fabric Java contract missing private data methods

The Java contract for fabric is missing the private data methods that currently exist in the nodeJS contract:

  • add
  • batch add
  • get
  • batch get

In order to benchmark these for Java, they need to be added

Manifest for hyperledger/fabric-ccenv:latest not found

Docker version: 19.03.13
Docker-compose version: 1.22.0

When I run

npx caliper launch manager --caliper-workspace . --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig networks/fabric/v1/v1.4.0/2org1peergoleveldb/fabric-go.yaml

I got this

2020.10.06-02:53:35.401 info [caliper] [cli-launch-manager] Set workspace path: /home/yyang/caliper-benchmarks
2020.10.06-02:53:35.402 info [caliper] [cli-launch-manager] Set benchmark configuration path: /home/yyang/caliper-benchmarks/benchmarks/scenario/simple/config.yaml
2020.10.06-02:53:35.402 info [caliper] [cli-launch-manager] Set network configuration path: /home/yyang/caliper-benchmarks/networks/fabric/v1/v1.4.0/2org1peergoleveldb/fabric-go.yaml
2020.10.06-02:53:35.402 info [caliper] [cli-launch-manager] Set SUT type: fabric
2020.10.06-02:53:35.422 info [caliper] [benchmark-validator] No observer specified, will default to none
2020.10.06-02:53:35.422 info [caliper] [caliper-engine] Starting benchmark flow
2020.10.06-02:53:35.826 info [caliper] [fabric-connector] Initializing standard connector compatible with installed SDK: 1.4.11
2020.10.06-02:53:35.932 info [caliper] [caliper-utils] Executing command: cd .; export FABRIC_VERSION=1.4.0;export FABRIC_CA_VERSION=1.4.0;docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb/docker-compose.yaml up -d;sleep 3s
Creating network "2org1peergoleveldb_default" with the default driver
Creating ca.org1.example.com ... done
Creating orderer.example.com ... done
Creating ca.org2.example.com ... done
Creating peer0.org2.example.com ... done
Creating peer0.org1.example.com ... done
2020.10.06-02:53:43.911 info [caliper] [caliper-engine] Executed start command in 7.979 seconds
2020.10.06-02:53:43.911 info [caliper] [connectors/v1/fabric] Fabric SDK version: 1.4.11; TLS: none
2020.10.06-02:53:44.385 info [caliper] [connectors/v1/fabric] Org1's registrar enrolled successfully
2020.10.06-02:53:44.555 info [caliper] [connectors/v1/fabric] Org2's registrar enrolled successfully
2020.10.06-02:53:44.578 info [caliper] [connectors/v1/fabric] Org1's admin's materials are successfully loaded
2020.10.06-02:53:44.581 info [caliper] [connectors/v1/fabric] Org2's admin's materials are successfully loaded
2020.10.06-02:53:44.584 info [caliper] [connectors/v1/fabric] client0.org1.example.com's materials are successfully loaded
2020.10.06-02:53:44.586 info [caliper] [connectors/v1/fabric] client0.org2.example.com's materials are successfully loaded
2020.10.06-02:53:44.586 info [caliper] [connectors/v1/fabric] Channel 'mychannel' definiton being retrieved from file
2020.10.06-02:53:44.663 info [caliper] [connectors/v1/fabric] Channel 'mychannel' successfully created
2020.10.06-02:53:44.663 info [caliper] [connectors/v1/fabric] Sleeping 5s...
2020.10.06-02:53:49.754 info [caliper] [connectors/v1/fabric] Org1's peers successfully joined mychannel: peer0.org1.example.com
2020.10.06-02:53:49.825 info [caliper] [connectors/v1/fabric] Org2's peers successfully joined mychannel: peer0.org2.example.com
2020.10.06-02:53:49.826 info [caliper] [connectors/v1/fabric] Sleeping 5s...
2020.10.06-02:53:54.827 info [caliper] [caliper-engine] Executed "init" step in 10.916 seconds
2020.10.06-02:53:54.827 info [caliper] [connectors/v1/fabric] Installing contracts for mychannel...
2020.10.06-02:53:54.857 info [caliper] [connectors/v1/fabric] marbles@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.10.06-02:53:54.864 info [caliper] [connectors/v1/fabric] marbles@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.10.06-02:53:54.889 info [caliper] [connectors/v1/fabric] drm@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.10.06-02:53:54.897 info [caliper] [connectors/v1/fabric] drm@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.10.06-02:53:54.913 info [caliper] [connectors/v1/fabric] simple@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.10.06-02:53:54.920 info [caliper] [connectors/v1/fabric] simple@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.10.06-02:53:54.937 info [caliper] [connectors/v1/fabric] smallbank@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.10.06-02:53:54.942 info [caliper] [connectors/v1/fabric] smallbank@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.10.06-02:53:54.943 info [caliper] [connectors/v1/fabric] Instantiating marbles@v0 in mychannel. This might take some time...
2020.10.06-02:53:55.184 error [caliper] [caliper-engine] Error while performing "install" step: Error: Invalid endorsement for marbles@v0 in mychannel from peer0.org1.example.com: error starting container: error starting container: Failed to generate platform-specific docker build: Failed to pull hyperledger/fabric-ccenv:latest: API error (404): manifest for hyperledger/fabric-ccenv:latest not found: manifest unknown: manifest unknown
2020.10.06-02:53:55.185 info [caliper] [caliper-engine] Executed "install" step in 0.358 seconds
2020.10.06-02:53:55.185 info [caliper] [caliper-utils] Executing command: cd .; docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb/docker-compose.yaml down;(test -z "$(docker ps -aq)") || docker rm $(docker ps -aq);(test -z "$(docker images dev* -q)") || docker rmi $(docker images dev* -q);rm -rf /tmp/hfc-*
The FABRIC_CA_VERSION variable is not set. Defaulting to a blank string.
The FABRIC_VERSION variable is not set. Defaulting to a blank string.
Stopping peer0.org2.example.com ... done
Stopping peer0.org1.example.com ... done
Stopping ca.org2.example.com ... done
Stopping orderer.example.com ... done
Stopping ca.org1.example.com ... done
Removing peer0.org2.example.com ... done
Removing peer0.org1.example.com ... done
Removing ca.org2.example.com ... done
Removing orderer.example.com ... done
Removing ca.org1.example.com ... done
Removing network 2org1peergoleveldb_default
"docker rm" requires at least 1 argument.
See 'docker rm --help'.

Usage: docker rm [OPTIONS] CONTAINER [CONTAINER...]

Remove one or more containers
"docker rmi" requires at least 1 argument.
See 'docker rmi --help'.

Usage: docker rmi [OPTIONS] IMAGE [IMAGE...]

Remove one or more images
2020.10.06-02:54:06.171 info [caliper] [caliper-engine] Executed end command in 10.986 seconds
2020.10.06-02:54:06.172 error [caliper] [cli-launch-manager] Benchmark failed with error code 5
Usage:
caliper launch manager --caliper-bind-sut fabric:1.4 [other options]

Options:
--help, -h Show usage information [boolean]
--version Show version information [boolean]
--caliper-bind-sut The name and version of the platform to bind to [string]
--caliper-bind-cwd The working directory for performing the SDK install [string]
--caliper-bind-args Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter [string]
--caliper-bind-file Yaml file to override default (supported) package versions when binding an SDK [string]

Error: Benchmark failed with error code 5
at Function.handler (/home/yyang/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/launch/lib/launchManager.js:70:23)
at process._tickCallback (internal/process/next_tick.js:68:7)

I have googled it, it's said that the latest tag isn't available anymore. How can I solve this issue?

Unable to run any v1.4.1 Raft benchmarks

Trying to run a Raft benchmark with Fabric V1.4.1:
npx caliper launch master --caliper-workspace . --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peergoleveldb_raft/fabric-go-tls-solo.yaml

### Outcome:

2020.04.23-07:26:15.413 info  [caliper] [adapters/fabric] 	Instantiating marbles@v0 in mychannel. This might take some time...
2020.04.23-07:26:40.572 error [caliper] [caliper-engine] 	Error while performing "install" step: Error: Invalid endorsement for marbles@v0 in mychannel from peer0.org1.example.com: error starting container: error starting container: API error (404): network 2org1peergoleveldb_solo_raft_default not found
2020.04.23-07:26:40.573 info  [caliper] [caliper-engine] 	Executed "install" step in 25.497 seconds

Peer log:

root@ubuntu:~# docker logs -f peer0.org1.example.com
2020-04-23 07:25:52.968 UTC [nodeCmd] createChaincodeServer -> WARN 001 peer.chaincodeListenAddress is not set, using peer0.org1.example.com:7052
2020-04-23 07:25:52.971 UTC [chaincode] getLogLevelFromViper -> WARN 002 chaincode.logging.level has invalid log level WARN. defaulting to WARN
2020-04-23 07:25:52.972 UTC [chaincode] getLogLevelFromViper -> WARN 003 chaincode.logging.shim has invalid log level WARN. defaulting to WARN
2020-04-23 07:26:40.518 UTC [dockercontroller] Start -> ERRO 004 start-could not start container: API error (404): network 2org1peergoleveldb_solo_raft_default not found
2020-04-23 07:26:40.547 UTC [endorser] SimulateProposal -> ERRO 005 [mychannel][29dbeb42] failed to invoke chaincode name:"lscc" , error: API error (404): network 2org1peergoleveldb_solo_raft_default not found
error starting container
error starting container
2020-04-23 07:26:41.345 UTC [deliveryClient] try -> WARN 006 Got error: rpc error: code = Canceled desc = context canceled , at 1 attempt. Retrying in 1s
2020-04-23 07:26:41.345 UTC [blocksProvider] DeliverBlocks -> WARN 007 [mychannel] Receive error: client is closing

I have generated the cryptomaterial. I am also able to run the non-Raft versions of the same benchmark.

Ethereum Existing Blockchain Nonce Issue

Hey, I am trying to run ethereum benchmarks on my existing blockchain so far I have come across multiple error including

  • Gas Issue (Apparently the contract compiled by my truffle does not have a gas specified which I have to manually specify while executing the benchmarks)

  • After specifying gas price in the contract build I don't still don't get it in the init.js so I have to specify again.
    contx.contracts.ProofC.gas = 67219750
    contx.contracts.ProofC.estimateGas = 60000000

  • The above two issues I have overcome but not I am getting nonce issues. In run inside init.js I am repeatedly getting same nonce back which causes the first transaction to run and all others to fail.

Please note that I was able to run the existing sample benchmark flawlessly but for actual benchmark of my existing contract I have to use oraclize and as its running fine using web3 and metamask I just want to get performance indicators of my existing setup also right now i am not concerned with the gas estimate or cost i just want to have a benchmark on performance not the gas price used.

I have been stuck in this issue from a month please guide me and let me know anything you need.
Thanks in advance. Any help will be much appreciated.

Truffle using to compile the contracts:

module.exports = {
// See http://truffleframework.com/docs/advanced/configuration
// for more about customizing your Truffle configuration!
networks: {
development: {
host: "127.0.0.1",
port: 8545,
network_id: "*" // Match any network id
}
},
compilers: {
solc: {
version: "0.4.24",
settings: {
optimizer: {
enabled: true,
runs: 2000
},
},
optimizer: {
enabled: true,
runs: 2000
},
}
}

};
============================ OUTPUT ================

2020.06.09-03:50:23.505 info  [caliper] [message-handler] 	Handling "test" message
----------Nonces----------
{ '0x8c1F7A07D5592Fb6c7E1530738368447045B3366': 43 }
2020.06.09-03:50:23.507 info  [caliper] [caliper-local-client.js] 	Info: client 1 start test runFixedNumber():Creating Proof chain.
----------Nonces----------
2020.06.09-03:50:23.508 info  [caliper] [message-handler] 	Handling "test" message
2020.06.09-03:50:23.508 info  [caliper] [caliper-local-client.js] 	txUpdateTime: 5000
{ '0x8c1F7A07D5592Fb6c7E1530738368447045B3366': 43 }
2020.06.09-03:50:23.510 info  [caliper] [caliper-local-client.js] 	txUpdateTime: 5000
2020.06.09-03:50:23.510 info  [caliper] [caliper-local-client.js] 	Info: client 2 start test runFixedNumber():Creating Proof chain.
2020.06.09-03:50:23.511 info  [caliper] [message-handler] 	Handling "test" message
----------Nonces----------
2020.06.09-03:50:23.512 info  [caliper] [caliper-local-client.js] 	Info: client 3 start test runFixedNumber():Creating Proof chain.
----------Nonces----------
{ '0x8c1F7A07D5592Fb6c7E1530738368447045B3366': 43 }
2020.06.09-03:50:23.513 info  [caliper] [caliper-local-client.js] 	txUpdateTime: 5000
{ '0x8c1F7A07D5592Fb6c7E1530738368447045B3366': 43 }
2020.06.09-03:50:23.515 info  [caliper] [caliper-local-client.js] 	Info: client 4 start test runFixedNumber():Creating Proof chain.
----------Nonces----------
{ '0x8c1F7A07D5592Fb6c7E1530738368447045B3366': 43 }
2020.06.09-03:50:23.675 error [caliper] [ethereum.js] 	Failed tx on ProofC calling method isVerified nonce 0x2b
2020.06.09-03:50:23.676 error [caliper] [ethereum.js] 	Error: Returned error: the tx doesn't have the correct nonce. account has nonce of: 44 tx has nonce of: 43
2020.06.09-03:50:23.682 error [caliper] [ethereum.js] 	Failed tx on ProofC calling method isVerified nonce 0x2b
2020.06.09-03:50:23.682 error [caliper] [ethereum.js] 	Error: Returned error: the tx doesn't have the correct nonce. account has nonce of: 44 tx has nonce of: 43
2020.06.09-03:50:23.739 error [caliper] [ethereum.js] 	Failed tx on ProofC calling method isVerified nonce 0x2b
2020.06.09-03:50:23.740 error [caliper] [ethereum.js] 	Error: Returned error: the tx doesn't have the correct nonce. account has nonce of: 44 tx has nonce of: 43
2020.06.09-03:50:23.746 error [caliper] [ethereum.js] 	Failed tx on ProofC calling method isVerified nonce 0x2b
2020.06.09-03:50:23.746 error [caliper] [ethereum.js] 	Error: Returned error: the tx doesn't have the correct nonce. account has nonce of: 44 tx has nonce of: 43
2020.06.09-03:50:23.908 info  [caliper] [message-handler] 	Handled "test" message for worker 0
2020.06.09-03:50:23.915 info  [caliper] [message-handler] 	Handled "test" message for worker 3
2020.06.09-03:50:23.942 info  [caliper] [message-handler] 	Handled "test" message for worker 1
2020.06.09-03:50:23.948 info  [caliper] [message-handler] 	Handled "test" message for worker 4
2020.06.09-03:50:23.953 info  [caliper] [message-handler] 	Handled "test" message for worker 2
2020.06.09-03:50:23.958 info  [caliper] [report-builder] 	### Test result ###
2020.06.09-03:50:23.964 info  [caliper] [report-builder] 	
+------+------+------+-----------------+-----------------+-----------------+-----------------+------------------+
| Name | Succ | Fail | Send Rate (TPS) | Max Latency (s) | Min Latency (s) | Avg Latency (s) | Throughput (TPS) |
|------|------|------|-----------------|-----------------|-----------------|-----------------|------------------|
| init | 1    | 4    | 454.5           | 0.24            | 0.24            | 0.24            | 4.1              |
+------+------+------+-----------------+-----------------+-----------------+-----------------+------------------+

2020.06.09-03:50:23.967 info  [caliper] [round-orchestrator] 	Finished round 1 (init) in 0.19 seconds

========================= init.js ======================================

'use strict';

const web3 = require('web3')

module.exports.info = 'Creating Proof chain.';

let bc, contx;
let runTimes = 0
module.exports.init = function (blockchain, context, args) {
bc = blockchain;
contx = context;

return Promise.resolve();

};

module.exports.run = async function () {
let args;

var fromAddress = '0x8c1F7A07D5592Fb6c7E1530738368447045B3366';

console.log("----------Nonces----------")
console.log(contx.nonces)
contx.contracts.ProofC.gas = 67219750
contx.contracts.ProofC.estimateGas = 60000000

let invokeData = [];
// if (bc.getType() === 'ethereum') {
invokeData = [{
    verb: 'isVerified',
    args: [web3.utils.asciiToHex('resourceinn.com')]
}];

// }


return bc.invokeSmartContract(contx, 'ProofC', '', invokeData, 60);

};

module.exports.end = function () {
return Promise.resolve();
};

================== Run Command ==============
npx caliper launch master --caliper-bind-sut ethereum:latest --caliper-benchconfig benchmarks/samples/ethereum/config.yaml --caliper-networkconfig networks/ethereum/1node/ethereum.json --caliper-workspace ./

TypeError: Path must be a string. Received Undefined.

Hi everyone:
I recently installed Caliper v2.0 on Ubuntu18 but when I'm running a sample benchmark on hyperledger 1.0.0 I keep getting this error: TypeError: Path must be a string. Received Undefined.
Apparently, the tool is not recognizing the path of the config files. Just so you know, the same syntax has worked before without any problem. All the versions of the prerequisite tools (nodejs, make, git, npm, etc) seem to be on point. I'm kinda new to Linux and the tool so your kind help would be very much appreciated!
Thank you!

  • angelo

OUTPUT LOG:
angelo@angelo-VirtualBox:~/Caliper/caliper-benchmarks$ npx caliper benchmark run --caliper-benchonfig config.yaml --caliper-networkconfig fabric-go.yaml --caliper-workspace .
TypeError: Path must be a string. Received undefined
at assertPath (path.js:28:11)
at Object.isAbsolute (path.js:1222:5)
at Function.handler (/home/angelo/Caliper/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/benchmark/lib/runBenchmark.js:39:32)
at Object.module.exports.handler (/home/angelo/Caliper/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/benchmark/runBenchmarkCommand.js:52:43)
at Object.runCommand (/home/angelo/Caliper/caliper-benchmarks/node_modules/yargs/lib/command.js:228:22)
at Object.parseArgs [as _parseArgs] (/home/angelo/Caliper/caliper-benchmarks/node_modules/yargs/yargs.js:1013:30)
at Object.runCommand (/home/angelo/Caliper/caliper-benchmarks/node_modules/yargs/lib/command.js:194:45)
at Object.parseArgs [as _parseArgs] (/home/angelo/Caliper/caliper-benchmarks/node_modules/yargs/yargs.js:1013:30)
at Object.get [as argv] (/home/angelo/Caliper/caliper-benchmarks/node_modules/yargs/yargs.js:957:21)
at Object. (/home/angelo/Caliper/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/caliper.js:35:5)
Command failed

Cannot override default scrapePort

I'm running Caliper locally and since the scrapePort for the workers' defaults in 3000, it conflicts with Grafana port (also 3000).
I tried to change it as follows:

monitors:
    transaction:
    - module: prometheus
    options:
      interval: 5
      scrapePort: 4000

But it did not seem to work as the scrapePort for the workers would still start from 300. For now I fixed the issue temporarily by changing the /caliper-benchmarks/node_modules/@hyperledger/caliper-core/lib/worker/tx-observers/prometheus-tx-observer.js,8157,1605195368000:

        if (CaliperUtils.isForkedProcess()) {
            this.scrapePort += workerIndex+1;
        }

Well, it's not an ideal solution I guess.

Multiple errors in Sawtooth simple network example

1. Contract src path error in Dockerfile

The following paths are incorrect in the Dockerfile, resulting in a build failure:

WORKDIR /project/src/sawtooth/simple/simple_python
ENV PATH "$PATH:/project/:/project/src/sawtooth/simple/simple_python:."

The build error:

ERROR: for simple-tp-python  Cannot start service simple-tp-python: OCI runtime create failed: container_linux.go:349: starting container process caused "exec: \"simple-tp-python\": executable file not found in $PATH": unknown

Since the benchmark repo root is mounted as the /project/ dir in the container, the correct path should be /project/src/sawtooth/scenario/simple/simple_python (so the problem is the missing scenario path segment).

2. Contract src path error in network configuration

The same applies to the corresponding network configuration file:

"batchBuilders": {
"simple": {
"1.0": "src/sawtooth/simple/SimpleBatchBuilder.js"

Resulting in:

2020.04.08-12:55:00.968 error [caliper] [sawtooth.js] 	invokeSmartContract failed, Error: Unable to load batch builder for simple[1.0] at src/sawtooth/simple/SimpleBatchBuilder.js::Cannot find module '/home/klenik/projects/caliper-benchmarks/src/sawtooth/simple/SimpleBatchBuilder.js'

3. Incorrect package name error

The required Sawtooth package name is also incorrect in the SimpleBatchBuilder.js module:

const BatchBuilder = require('caliper-sawtooth').BatchBuilder;

Resulting in:

2020.04.08-13:02:57.014 error [caliper] [sawtooth.js] 	invokeSmartContract failed, Error: Unable to load batch builder for simple[1.0] at src/sawtooth/scenario/simple/SimpleBatchBuilder.js::Cannot find module 'caliper-sawtooth'

4. Missing dependency in batch builder

The cbor dependency is required, but not installed automatically:

The dependency could be added to the start script.

Resulting error:

2020.04.08-13:08:07.241 error [caliper] [sawtooth.js] 	invokeSmartContract failed, Error: Cannot find module 'cbor'

5. Incompatible batch builder with transfer function

The following place has hard-coded invoke argument names, which do not match the account1 and account2 attributes of the transfer arguments:

Error running benchmark on version 0.4.0 | Hyperledger Fabric 2.1.0

Hello, I have been facing the following issue for the last 5 days.

2020.10.10-14:03:17.130 info  [caliper] [caliper-local-client]  Client[0] encountered an error during prepare test phase: Error: 14 UNAVAILABLE: Connection dropped
    at Object.callErrorFromStatus (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/call.js:30:26)
    at Object.onReceiveStatus (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/client.js:175:52)
    at Object.onReceiveStatus (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/client-interceptors.js:341:141)
    at Object.onReceiveStatus (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/client-interceptors.js:304:181)
    at Http2CallStream.outputStatus (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/call-stream.js:115:74)
    at Http2CallStream.maybeOutputStatus (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/call-stream.js:154:22)
    at Http2CallStream.endCall (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/call-stream.js:140:18)
    at Http2CallStream.disconnectListener (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/call-stream.js:102:18)
    at Socket.session.socket.once (/home/erodotos/Desktop/Hyperledger-Fabric-Network/caliper-workspace/node_modules/@grpc/grpc-js/build/src/subchannel.js:341:25)
    at Object.onceWrapper (events.js:315:30)

I have delved into the caliper documentation searching for a solution, though I didn't find one. What might be going wrong?

These are my benchmark and network config files :

---
test:
  name: simple test
  description: This is an example benchmark using caliper
  workers:
    type: local
    number: 1
  rounds:
    - label: write
      txNumber: 100
      rateControl:
        type: fixed-rate
        opts:
          tps: 50
      workload: 
        module: workload/write.js
monitor:
  interval: 1
  type: ['docker']
  docker:
    containers: ['all']
name: Fabric
version: "1.0"

caliper:
  blockchain: fabric

info:
  Version: 2.1.0
  Size: 2 Orgs with 2 Peer
  Orderer: etcd - Raft,
  Distribution: Single Host
  StateDB: CouchDB

clients:
  client0.org1.example.com:
    client:
      organization: Org1
      credentialStore:
        path: /tmp/hfc-kvs/org1
        cryptoStore:
          path: /tmp/hfc-cvs/org1
      clientPrivateKey:
        path: ../network/organizations/peerOrganizations/org1.example.com/users/[email protected]/msp/keystore/priv_sk
      clientSignedCert:
        path: ../network/organizations/peerOrganizations/org1.example.com/users/[email protected]/msp/signcerts/[email protected]

  client0.org2.example.com:
    client:
      organization: Org2
      credentialStore:
        path: /tmp/hfc-kvs/org2
        cryptoStore:
          path: /tmp/hfc-cvs/org2
      clientPrivateKey:
        path: ../network/organizations/peerOrganizations/org2.example.com/users/[email protected]/msp/keystore/priv_sk
      clientSignedCert:
        path: ../network/organizations/peerOrganizations/org2.example.com/users/[email protected]/msp/signcerts/[email protected]

channels:
  mychannel:
    configBinary: ../network/channel-artifacts/mychannel.tx
    created: true
    orderers:
      - orderer.example.com
    peers:
      peer0.org1.example.com:
        eventSource: true
      peer1.org1.example.com:
        eventSource: true
      peer0.org2.example.com:
        eventSource: true
      peer1.org2.example.com:
        eventSource: true

    contracts:
      - id: rawOne
        version: "1"
        language: golang
        path: chaincode/src/rawOne/

organizations:
  Org1:
    mspid: Org1MSP
    peers:
      - peer0.org1.example.com
    adminPrivateKey:
      path: ../network/organizations/peerOrganizations/org1.example.com/users/[email protected]/msp/keystore/priv_sk
    signedCert:
      path: ../network/organizations/peerOrganizations/org1.example.com/users/[email protected]/msp/signcerts/[email protected]

  Org2:
    mspid: Org2MSP
    peers:
      - peer0.org2.example.com
    adminPrivateKey:
      path: ../network/organizations/peerOrganizations/org2.example.com/users/[email protected]/msp/keystore/priv_sk
    signedCert:
      path: ../network/organizations/peerOrganizations/org2.example.com/users/[email protected]/msp/signcerts/[email protected]

orderers:
  orderer.example.com:
    url: grpc://localhost:7050
    grpcOptions:
      ssl-target-name-override: orderer.example.com

peers:
  peer0.org1.example.com:
    url: grpc://localhost:7051
    grpcOptions:
      ssl-target-name-override: peer0.org1.example.com
      grpc.keepalive_time_ms: 120000

  peer1.org1.example.com:
    url: grpc://localhost:8051
    grpcOptions:
      ssl-target-name-override: peer1.org1.example.com
      grpc.keepalive_time_ms: 120000

  peer0.org2.example.com:
    url: grpc://localhost:9051
    grpcOptions:
      ssl-target-name-override: peer0.org2.example.com
      grpc.keepalive_time_ms: 120000

  peer1.org2.example.com:
    url: grpc://localhost:10051
    grpcOptions:
      ssl-target-name-override: peer1.org2.example.com
      grpc.keepalive_time_ms: 120000

[NetworkConfig101.js]: NetworkConfig101 - problem reading the PEM file

I am installing hyperledger caliber using the local NPM found at https://hyperledger.github.io/caliper/v0.3/installing-caliper/. Once I invoke the local CLI binary (step 4) using the command,
npx caliper launch master
--caliper-workspace .
--caliper-benchconfig benchmarks/scenario/simple/config.yaml
--caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peergoleveldb/fabric-go.yaml

I got the following log error:
2020.04.24-15:24:19.250 info [caliper] [cli-launch-master] Set workspace path: /root/go/src/github.com/hyperledger/caliper/caliper-benchmarks
2020.04.24-15:24:19.253 info [caliper] [cli-launch-master] Set benchmark configuration path: /root/go/src/github.com/hyperledger/caliper/caliper-benchmarks/benchmarks/scenario/simple/config.yaml
2020.04.24-15:24:19.253 info [caliper] [cli-launch-master] Set network configuration path: /root/go/src/github.com/hyperledger/caliper/caliper-benchmarks/networks/fabric/fabric-v1.4.1/2org1peergoleveldb/fabric-go-tls.yaml
2020.04.24-15:24:19.253 info [caliper] [cli-launch-master] Set SUT type: fabric
2020.04.24-15:24:19.270 info [caliper] [benchmark-validator] No observer specified, will default to none
2020.04.24-15:24:19.276 info [caliper] [caliper-engine] Starting benchmark flow
2020.04.24-15:24:20.562 info [caliper] [adapters/fabric] Initializing standard adaptor compatible with installed SDK: 1.4.8
2020.04.24-15:24:20.981 info [caliper] [caliper-utils] Executing command: cd caliper-benchmarks; export FABRIC_VERSION=1.4.1;export FABRIC_CA_VERSION=1.4.1;docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb/docker-compose-tls.yaml up -d;sleep 3s
Creating network "2org1peergoleveldb_default" with the default driver
Creating ca.org1.example.com ... done
Creating orderer.example.com ... done
Creating ca.org2.example.com ... done
Creating peer0.org1.example.com ... done
Creating peer0.org2.example.com ... done
2020.04.24-15:24:31.463 info [caliper] [caliper-engine] Executed start command in 10.483 seconds
2020.04.24-15:24:31.464 info [caliper] [adapters/fabric] Fabric SDK version: 1.4.8; TLS: server
2020-04-24T07:24:31.492Z - error: [NetworkConfig101.js]: NetworkConfig101 - problem reading the PEM file :: Error: ENOENT: no such file or directory, open '/root/go/src/github.com/hyperledger/caliper/caliper-benchmarks/networks/fabric/config_solo/crypto-config/peerOrganizations/org1.example.com/tlsca/tlsca.org1.example.com-cert.pem'
2020.04.24-15:24:31.494 error [caliper] [caliper-engine] Error while performing "init" step: Error: ENOENT: no such file or directory, open '/root/go/src/github.com/hyperledger/caliper/caliper-benchmarks/networks/fabric/config_solo/crypto-config/peerOrganizations/org1.example.com/tlsca/tlsca.org1.example.com-cert.pem'
2020.04.24-15:24:31.495 info [caliper] [caliper-engine] Executed "init" step in 0.031 seconds
2020.04.24-15:24:31.495 info [caliper] [caliper-utils] Executing command: cd caliper-benchmarks; docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb/docker-compose-tls.yaml down;(test -z "$(docker ps -aq)") || docker rm $(docker ps -aq);(test -z "$(docker images dev* -q)") || docker rmi $(docker images dev* -q);rm -rf /tmp/hfc-*
The FABRIC_CA_VERSION variable is not set. Defaulting to a blank string.
The FABRIC_VERSION variable is not set. Defaulting to a blank string.
Removing peer0.org2.example.com ... done
Removing peer0.org1.example.com ... done
Removing ca.org1.example.com ... done
Removing ca.org2.example.com ... done
Removing orderer.example.com ... done
Removing network 2org1peergoleveldb_default
"docker rm" requires at least 1 argument.
See 'docker rm --help'.

Usage: docker rm [OPTIONS] CONTAINER [CONTAINER...]

Remove one or more containers
"docker rmi" requires at least 1 argument.
See 'docker rmi --help'.

Usage: docker rmi [OPTIONS] IMAGE [IMAGE...]

Remove one or more images
2020.04.24-15:24:33.217 info [caliper] [caliper-engine] Executed end command in 1.721 seconds
2020.04.24-15:24:33.217 error [caliper] [cli-launch-master] Benchmark failed with error code 4
Usage:
caliper launch master --caliper-bind-sut fabric:1.4.1 [other options]

Options:
--help, -h Show usage information [布尔]
--version Show version information [布尔]
--caliper-bind-sut The name and version of the platform to bind to [字符串]
--caliper-bind-cwd The working directory for performing the SDK install [字符串]
--caliper-bind-args Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter [字符串]
--caliper-bind-file Yaml file to override default (supported) package versions when binding an SDK [字符串]

Error: Benchmark failed with error code 4
at Function.handler (/root/go/src/github.com/hyperledger/caliper/packages/caliper-cli/lib/launch/lib/launchMaster.js:70:23)
at
at process._tickCallback (internal/process/next_tick.js:188:7)

Negative values in the benchmark reports

This happens when the default config file in the simple scenario is changed (e.g., increasing TPS):

image

Config.yaml:

simpleArgs: &simple-args
  initialMoney: 10000
  moneyToTransfer: 100
  numberOfAccounts: &number-of-accounts 2000

test:
  name: simple
  description: >-
    This is an example benchmark for Caliper, to test the backend DLT's
    performance with simple account opening & querying transactions.
  workers:
    type: local
    number: 5
  rounds:
    - label: open
      description: >-
        Test description for the opening of an account through the deployed
        contract.
      txNumber: *number-of-accounts
      rateControl:
        type: fixed-rate
        opts:
          tps: 500
      workload:
        module: benchmarks/scenario/simple/open.js
        arguments: *simple-args

Parsed to:

Test Environment

benchmark config
name: simple
description: >-
  This is an example benchmark for Caliper, to test the backend DLT's
  performance with simple account opening & querying transactions.
workers:
  type: local
  number: 5
rounds:
  - label: open
    description: >-
      Test description for the opening of an account through the deployed
      contract.
    txNumber: 2000
    rateControl:
      type: fixed-rate
      opts:
        tps: 500
    workload:
      module: benchmarks/scenario/simple/open.js
      arguments:
        initialMoney: 10000
        moneyToTransfer: 100
        numberOfAccounts: 2000

Remnant fabric-ccp checks in callback modules

Current behavior

The following callback still use the "fabric-ccp" string when assembling the TX settings, which will usually result in invalid chaincode arguments.

Affected files (according to grep):

klenik@ubuntu:~/projects/caliper-benchmarks$ grep -R --exclude-dir='.git' 'fabric-ccp' .
./benchmarks/scenario/smallbank/smallbankOperations.js:    if (bc.bcType === 'fabric-ccp') {
./benchmarks/scenario/smallbank/query.js:    if (bc.bcType === 'fabric-ccp') {
./benchmarks/scenario/simple/open.js:        if (bc.bcType === 'fabric-ccp') {
./benchmarks/scenario/simple/transfer.js:    if (bc.bcType === 'fabric-ccp') {
./benchmarks/scenario/simple/query.js:    if (bc.bcType === 'fabric-ccp') {

Fix

klenik@ubuntu:~/projects/caliper-benchmarks$ find . -type f -not -path '*/\.*' -exec sed -i 's/fabric-ccp/fabric/g' {} +

Confirm with another grep.

Error when running benchmark: API error (404): network 2org1peergoleveldb_raft_default not found

I'm trying to run the following benchmark:

Command:
px caliper launch master --caliper-benchconfig benchmarks/samples/fabric/marbles/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peergoleveldb_raft/fabric-go-tls.yaml --caliper-workspace ../caliper-benchmarks-v1/

[ Note that I'm running the above command from a directory named 'caliper' where caliper is installed (through NPM) ]

I get the following error:
020.07.06-04:14:28.335 error [caliper] [caliper-engine] Error while performing "install" step: Error: Invalid endorsement for marbles@v0 in mychannel from peer0.org1.example.com: error starting container: error starting container: API error (404): network 2org1peergoleveldb_raft_default not found

Complete output:
hlf/caliper$ npx caliper launch master --caliper-benchconfig benchmarks/samples/fabric/marbles/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peergoleveldb_raft/fabric-go-tls.yaml --caliper-workspace ../caliper-benchmarks-v1/
2020.07.06-04:13:41.643 info [caliper] [cli-launch-master] Set workspace path: /mnt/c/data/code/cpp/project8/hlf/caliper-benchmarks-v1
2020.07.06-04:13:41.644 info [caliper] [cli-launch-master] Set benchmark configuration path: /mnt/c/data/code/cpp/project8/hlf/caliper-benchmarks-v1/benchmarks/samples/fabric/marbles/config.yaml
2020.07.06-04:13:41.645 info [caliper] [cli-launch-master] Set network configuration path: /mnt/c/data/code/cpp/project8/hlf/caliper-benchmarks-v1/networks/fabric/fabric-v1.4.1/2org1peergoleveldb_raft/fabric-go-tls.yaml
2020.07.06-04:13:41.645 info [caliper] [cli-launch-master] Set SUT type: fabric
2020.07.06-04:13:41.739 info [caliper] [benchmark-validator] No observer specified, will default to none
2020.07.06-04:13:41.740 info [caliper] [caliper-engine] Starting benchmark flow
2020.07.06-04:13:41.847 info [caliper] [adapters/fabric] Initializing standard adaptor compatible with installed SDK: 1.4.1
2020.07.06-04:13:48.148 info [caliper] [caliper-utils] Executing command: cd ../caliper-benchmarks-v1/; export FABRIC_VERSION=1.4.1;export FABRIC_CA_VERSION=1.4.1;docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb_raft/docker-compose-tls.yaml up -d;sleep 3s
Creating network "2org1peergoleveldbraft_default" with the default driver
Creating ca.org2.example.com ...
Creating ca.org1.example.com ...
Creating ca.org1.example.com
Creating ca.org1.example.com ... done
Creating orderer0.example.com ...
Creating orderer2.example.com ...
Creating orderer1.example.com ...
Creating orderer0.example.com
Creating orderer2.example.com
Creating orderer0.example.com ... done
Creating peer0.org1.example.com ...
Creating peer0.org2.example.com ...
Creating peer0.org1.example.com
Creating peer0.org1.example.com ... done
2020.07.06-04:13:54.686 info [caliper] [caliper-engine] Executed start command in 6.538 seconds
2020.07.06-04:13:54.687 info [caliper] [adapters/fabric] Fabric SDK version: 1.4.1; TLS: server
2020.07.06-04:13:56.958 info [caliper] [adapters/fabric] Org1's registrar enrolled successfully
2020.07.06-04:13:57.156 info [caliper] [adapters/fabric] Org2's registrar enrolled successfully
2020.07.06-04:13:57.198 info [caliper] [adapters/fabric] Org1's admin's materials are successfully loaded
2020.07.06-04:13:57.239 info [caliper] [adapters/fabric] Org2's admin's materials are successfully loaded
2020.07.06-04:13:57.274 info [caliper] [adapters/fabric] client0.org1.example.com's materials are successfully loaded
2020.07.06-04:13:57.307 info [caliper] [adapters/fabric] client0.org2.example.com's materials are successfully loaded
2020.07.06-04:13:57.308 info [caliper] [adapters/fabric] Channel 'mychannel' definiton being retrieved from file
2020.07.06-04:13:57.445 info [caliper] [adapters/fabric] Channel 'mychannel' successfully created
2020.07.06-04:13:57.446 info [caliper] [adapters/fabric] Sleeping 5s...
2020.07.06-04:14:02.613 info [caliper] [adapters/fabric] Org1's peers successfully joined mychannel: peer0.org1.example.com
2020.07.06-04:14:02.696 info [caliper] [adapters/fabric] Org2's peers successfully joined mychannel: peer0.org2.example.com
2020.07.06-04:14:02.696 info [caliper] [adapters/fabric] Sleeping 5s...
2020.07.06-04:14:07.698 info [caliper] [caliper-engine] Executed "init" step in 13.012 seconds
2020.07.06-04:14:07.699 info [caliper] [adapters/fabric] Installing chaincodes for mychannel...
2020.07.06-04:14:07.850 info [caliper] [adapters/fabric] marbles@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.07.06-04:14:07.966 info [caliper] [adapters/fabric] marbles@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.07.06-04:14:08.012 info [caliper] [adapters/fabric] drm@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.07.06-04:14:08.037 info [caliper] [adapters/fabric] drm@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.07.06-04:14:08.076 info [caliper] [adapters/fabric] simple@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.07.06-04:14:08.104 info [caliper] [adapters/fabric] simple@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.07.06-04:14:08.150 info [caliper] [adapters/fabric] smallbank@v0 successfully installed on Org1's peers: peer0.org1.example.com
2020.07.06-04:14:08.176 info [caliper] [adapters/fabric] smallbank@v0 successfully installed on Org2's peers: peer0.org2.example.com
2020.07.06-04:14:08.177 info [caliper] [adapters/fabric] Instantiating marbles@v0 in mychannel. This might take some time...
2020.07.06-04:14:28.335 error [caliper] [caliper-engine] Error while performing "install" step: Error: Invalid endorsement for marbles@v0 in mychannel from peer0.org1.example.com: error starting container: error starting container: API error (404): network 2org1peergoleveldb_raft_default not found
2020.07.06-04:14:28.335 info [caliper] [caliper-engine] Executed "install" step in 20.637 seconds
2020.07.06-04:14:28.336 info [caliper] [caliper-utils] Executing command: cd ../caliper-benchmarks-v1/; docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb_raft/docker-compose-tls.yaml down;(test -z "$(docker ps -aq)") || docker rm $(docker ps -aq);(test -z "$(docker images dev* -q)") || docker rmi $(docker images dev* -q);rm -rf /tmp/hfc-*
The FABRIC_VERSION variable is not set. Defaulting to a blank string.
The FABRIC_CA_VERSION variable is not set. Defaulting to a blank string.
Stopping peer0.org2.example.com ... done
Stopping peer0.org1.example.com ... done
Stopping orderer1.example.com ... done
Stopping orderer0.example.com ... done
Stopping orderer2.example.com ... done
Stopping ca.org2.example.com ... done
Stopping ca.org1.example.com ... done
Removing peer0.org2.example.com ... done
Removing peer0.org1.example.com ... done
Removing orderer1.example.com ... done
Removing orderer0.example.com ... done
Removing orderer2.example.com ... done
Removing ca.org2.example.com ... done
Removing ca.org1.example.com ... done
Removing network 2org1peergoleveldbraft_default
"docker rm" requires at least 1 argument.
See 'docker rm --help'.

Usage: docker rm [OPTIONS] CONTAINER [CONTAINER...]

Remove one or more containers
/bin/sh: 1: test: "9317c8325aaf: unexpected operator
Untagged: dev-peer0.org2.example.com-marbles-v0-82ec74ea3ac84a8926b1d7d3d256a2e2f41b74928c28cf4bcdbb5a7774a90f87:latest
Deleted: sha256:c760baa1a232716aacef6aeffabca863d93dd7a454e8a73ff17d7d6103413451
Deleted: sha256:cf89584c23f39801d2f6412ec7603fc2d3f28846e74a434cc3f1eadaf78e3a26
Deleted: sha256:2660d76d76ab2109acb7dcffff0a1170d0e3e311129a5d1eee674af54c0f71c8
Untagged: dev-peer0.org1.example.com-marbles-v0-d970bb5377683adf108a269e3670f7f9cbb849f3eff58fe19595ea3374a52ea0:latest
Deleted: sha256:9317c8325aafe8c7624ffd205b695abe1c7f2c46c87d4980772f17115ce35df5
Deleted: sha256:d0e19c2892807fcd319d932bf2239e7c89b4c2baad2b36d4b6059c255014f0e6
Deleted: sha256:c96cd030c621ead23639cc5f70f79fa27586b004351ab229c8f043e24c7861b9
Deleted: sha256:80763b943fd50d2d711207524b14c1b8297c6cb27111296f1b95286c6b66c503
2020.07.06-04:14:41.991 info [caliper] [caliper-engine] Executed end command in 13.656 seconds
2020.07.06-04:14:41.991 error [caliper] [cli-launch-master] Benchmark failed with error code 5
Usage:
caliper launch master --caliper-bind-sut fabric:1.4.1 [other options]

Options:
--help, -h Show usage information [boolean]
--version Show version information [boolean]
--caliper-bind-sut The name and version of the platform to bind to [string]
--caliper-bind-cwd The working directory for performing the SDK install [string]
--caliper-bind-args Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter [string]
--caliper-bind-file Yaml file to override default (supported) package versions when binding an SDK [string]

Error: Benchmark failed with error code 5
at Function.handler (/mnt/c/data/code/cpp/project8/hlf/caliper/node_modules/@hyperledger/caliper-cli/lib/launch/lib/launchMaster.js:70:23)
at
at process._tickCallback (internal/process/next_tick.js:188:7)

In v0.3.2 the Round 1 in create-asset seems to break the node SDK

Running create-asset.yaml in v0.3.2 with Caliper Bind(ed) to Fabric v2.1.0 with UTC being IBP Fabric network with images at Fabric v2.1.1

In create-asset.yaml all rounds are type: fixed-backlog except the first one (??!!) that its fixed-rate as shown below:

  • label: create-asset-8000-fixed-tps
    description: Test a submitTransaction() Gateway method against the NodeJS fixed-asset Smart Contract method named createAsset, which inserts an asset of size 8000 bytes into the World State database at a fixed TPS rate.
    chaincodeID: fixed-asset
    txDuration: 300
    rateControl: { type: fixed-rate, opts: { tps: 15} }
    arguments:
    chaincodeID: fixed-asset
    bytesize: 8000
    callback: benchmarks/api/fabric/lib/create-asset.js

I see two problems with this:

  1. Why different rate controls in the same create-asset.yaml?
  2. Round 1 in create-asset seems to breaks the node SDK with the error below. If I remove this fixed-rate round and leave all the others which are fixed-backlog then everything runs fine.

2020-08-12T23:14:43.294Z - error: [EventService]: send[ibp-jorge-peer11-peer.ibp25-dal10-jorge-bd8e586d66eff81119bfe4722b13dbd4-0000.us-south.containers.appdomain.cloud:443] - #1 - no targets started - Error: Event service ibp-jorge-peer11-peer.ibp25-dal10-jorge-bd8e586d66eff81119bfe4722b13dbd4-0000.us-south.containers.appdomain.cloud:443 is currently listening
2020-08-12T23:14:43.297Z - warn: [TransactionEventHandler]: strategyFail: commit failure for transaction "9bd982c0d86a54d5ba1f6a1b03dfc6596d32fa5f8abd1633e35be2762d9e963c": Error: No successful events received
(node:77242) UnhandledPromiseRejectionWarning: Error: No successful events received
at AnyForTxStrategy.checkCompletion (/Users/jorgego/Documents/CODE/caliper-benchmarks/caliper-benchmarks/node_modules/fabric-network/lib/impl/event/anyfortxstrategy.js:31:20)
at AnyForTxStrategy.errorReceived (/Users/jorgego/Documents/CODE/caliper-benchmarks/caliper-benchmarks/node_modules/fabric-network/lib/impl/event/transactioneventstrategy.js:61:14)
at TransactionEventHandler.eventCallback (/Users/jorgego/Documents/CODE/caliper-benchmarks/caliper-benchmarks/node_modules/fabric-network/lib/impl/event/transactioneventhandler.js:92:27)
at CommitListenerSession.start (/Users/jorgego/Documents/CODE/caliper-benchmarks/caliper-benchmarks/node_modules/fabric-network/lib/impl/event/commitlistenersession.js:27:18)
at process._tickCallback (internal/process/next_tick.js:68:7)
(node:77242) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
(node:77242) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

[Errno 2] No such file or directory: u'./networks/fabric/docker-compose/2org1peercouchdb_raft/docker-compose-tls.yaml'

When I run the following command for fabric-v1.4.1/2org1peercouchdb_raft.

mrx@devbox:~/code/caliper-benchmarks$ npx caliper benchmark run --caliper-benchconfig benchmarks/samples/fabric/marbles/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peercouchdb_raft/fabric-node-tls.yaml --caliper-workspace .

I get the file missing error. The whole folder is missing @ ./networks/fabric/docker-compose/2org1peercouchdb_raft/docker-compose-tls.yaml

mrx@devbox:~/code/caliper-benchmarks$ npx caliper benchmark run --caliper-benchconfig benchmarks/samples/fabric/marbles/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peercouchdb_raft/fabric-node-tls.yaml --caliper-workspace .
Benchmark for target Blockchain type fabric about to start
2020.01.19-14:46:59.955 info  [caliper] [benchmark-validator]   No observer specified, will default to `none`
2020.01.19-14:46:59.956 info  [caliper] [caliper-flow]  ####### Caliper Test #######
2020.01.19-14:46:59.958 info  [caliper] [null-observer]         Configured observer
2020.01.19-14:46:59.960 info  [caliper] [caliper-utils]         Executing command: cd /home/mrx/code/caliper-benchmarks;export FABRIC_VERSION=1.4.1;docker-compose -f networks/fabric/docker-compose/2org1peercouchdb_raft/docker-compose-tls.yaml up -d;sleep 3s
.IOError: [Errno 2] No such file or directory: u'./networks/fabric/docker-compose/2org1peercouchdb_raft/docker-compose-tls.yaml'
2020.01.19-14:47:03.286 info  [caliper] [adapters/fabric]       Fabric SDK version: 1.4.0; TLS: server
2020-01-19T14:47:03.645Z - error: [FabricCAClientService.js]: Failed to enroll admin, error:%o message=Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054], stack=Error: Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054]
    at ClientRequest.request.on (/home/mrx/code/caliper-benchmarks/node_modules/fabric-ca-client/lib/FabricCAClient.js:487:12)
    at ClientRequest.emit (events.js:198:13)
    at TLSSocket.socketErrorListener (_http_client.js:392:9)
    at TLSSocket.emit (events.js:198:13)
    at emitErrorNT (internal/streams/destroy.js:91:8)
    at emitErrorAndCloseNT (internal/streams/destroy.js:59:3)
    at process._tickCallback (internal/process/next_tick.js:63:19)
2020.01.19-14:47:03.646 error [caliper] [caliper-flow]  Error: Error: Couldn't enroll Org1's registrar or set it as user context: Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054]
    at Fabric._setUserContextByEnrollment (/home/mrx/code/caliper-benchmarks/node_modules/@hyperledger/caliper-fabric/lib/fabric.js:1688:19)
    at process._tickCallback (internal/process/next_tick.js:68:7)
2020.01.19-14:47:03.646 info  [caliper] [caliper-utils]         Executing command: cd /home/mrx/code/caliper-benchmarks;docker-compose -f networks/fabric/docker-compose/2org1peercouchdb_raft/docker-compose-tls.yaml down;(test -z \"$(docker ps -aq)\") || docker rm $(docker ps -aq);(test -z \"$(docker images dev* -q)\") || docker rmi $(docker images dev* -q);rm -rf /tmp/hfc-*
.IOError: [Errno 2] No such file or directory: u'./networks/fabric/docker-compose/2org1peercouchdb_raft/docker-compose-tls.yaml'
/bin/sh: 1: test: "fa8ed15fc798: unexpected operator
Error response from daemon: You cannot remove a running container fa8ed15fc79835a69dfe6dada3e5f907f5beeb774056991ab7833c02007778f6. Stop the container before attempting removal or force remove
Error response from daemon: You cannot remove a running container 0ad73430dcaa3ec8c69ae378dedf2d06e4e680ea0520cebd063db7538734aa94. Stop the container before attempting removal or force remove
Error response from daemon: You cannot remove a running container bc34fbe25920b5fd7f019c14774bd8b3ab6fd0e777c6d0f8f9c4f41f60b07bad. Stop the container before attempting removal or force remove
Error response from daemon: You cannot remove a running container 0d4aa7c95ea660fbb87a013e048bfc3a6d99746945ac9a1f95b78efd3292ee83. Stop the container before attempting removal or force remove
Error response from daemon: You cannot remove a running container f960ba1756d683b7beb753fdfaf3b3a1da64736340b312210e4be9c33eb73419. Stop the container before attempting removal or force remove
Error response from daemon: You cannot remove a running container 5f37162a3d9cd467cf32129523109c33b6801579bb4b1808158f79049f00d262. Stop the container before attempting removal or force remove
Error response from daemon: You cannot remove a running container b99485b68da20622c999e74b39f549968d9d67e7131bd8f868a8574ab1041cbb. Stop the container before attempting removal or force remove
Error response from daemon: You cannot remove a running container 165991e9be98419252305db60d1df55494326ad4dc8a9938574a24685457b5dd. Stop the container before attempting removal or force remove
"docker rmi" requires at least 1 argument.
See 'docker rmi --help'.

Usage:  docker rmi [OPTIONS] IMAGE [IMAGE...]

Remove one or more images
Benchmark failure
Error: Benchmark failure
    at Function.handler (/home/mrx/code/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/benchmark/lib/runBenchmark.js:70:23)
    at process._tickCallback (internal/process/next_tick.js:68:7)
Command failed

mrx@devbox:~/code/caliper-benchmarks$ 

all .pem files are missing

all "crypto-config" folders have been deleted from commit: e6e2eae on Apr 16, 2020. To make work the examples had to go pick from old commits.

Update workload modules according to new connector API

Modules to update to use sendRequests:

For invoke/querySmartContract:

./benchmarks/api/fabric/lib/helper.js
./benchmarks/scenario/smallbank/smallbankOperations.js
./benchmarks/scenario/smallbank/query.js
./benchmarks/scenario/simple/open.js
./benchmarks/scenario/simple/transfer.js
./benchmarks/scenario/simple/query.js
./benchmarks/samples/fisco-bcos/transfer/precompiled/addUser.js
./benchmarks/samples/fisco-bcos/transfer/precompiled/transfer.js
./benchmarks/samples/fisco-bcos/transfer/solidity/addUser.js
./benchmarks/samples/fisco-bcos/transfer/solidity/transfer.js
./benchmarks/samples/fisco-bcos/generate_txs_in_advance/addUser.js
./benchmarks/samples/fisco-bcos/helloworld/set.js
./benchmarks/samples/fabric/fabcar/changeCarOwner.js
./benchmarks/samples/fabric/fabcar/queryCar.js
./benchmarks/samples/fabric/fabcar/createCar.js
./benchmarks/samples/fabric/fabcar/helper.js
./benchmarks/samples/fabric/fabcar/queryAllCars.js
./benchmarks/samples/fabric/marbles/init.js
./benchmarks/samples/fabric/marbles/query.js

For queryState:

./benchmarks/scenario/smallbank/query.js
./benchmarks/scenario/simple/query.js
./benchmarks/samples/fisco-bcos/transfer/precompiled/transfer.js
./benchmarks/samples/fisco-bcos/transfer/solidity/transfer.js
./benchmarks/samples/fisco-bcos/generate_txs_in_advance/send.js
./benchmarks/samples/fisco-bcos/helloworld/get.js

error [caliper] [cli-launch-master] Unexpected error during benchmark execution: Error: Ethereum benchmarks must not use http(s) RPC connections, as there is no way to guarantee the order of submitted transactions when using other transports

Hello,
I am trying to launch caliper with ethereum configuration but I got this error: error [caliper] [cli-launch-master] Unexpected error during benchmark execution: Error: Ethereum benchmarks must not use http(s) RPC connections, as there is no way to guarantee the order of submitted transactions when using other transports
The command I run is: npx caliper launch master --caliper-bind-sut ethereum --caliper-workspace . --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig networks/ethereum/1node/ethereum.json
Thanks.

Error in simulation - Transaction does not exist

While using benchmark sample for fabcar, some data are not created hence creating failure in benchmark.

Context

When running caliper benchmark, I encounter some error saying Failed to perform query transaction [queryCar] using arguments [<carNumber>], with error: Error: error in simulation: transaction returned with failure: Error: <carNumber> does not exist. I tried to check what are the cause of this problem. Apparently cars are created using helper.js function and it skipped some car numbers even though it's supposed to be incremental without skipping.

2020.08.03-13:40:09.925 error [caliper] [adapters/fabric]       Failed to perform query transaction [queryCar] using arguments [Client1_CAR-2029091873174],  with error: Error: error in simulation: transaction returned with failure: Error: Client1_CAR-2029091873174 does not exist
2020.08.03-13:40:09.928 error [caliper] [adapters/fabric]       Failed to perform query transaction [queryCar] using arguments [Client4_CAR-2029091873177],  with error: Error: error in simulation: transaction returned with failure: Error: Client4_CAR-2029091873177 does not exist
2020.08.03-13:40:09.929 error [caliper] [adapters/fabric]       Failed to perform query transaction [queryCar] using arguments [Client3_CAR-2029091873179],  with error: Error: error in simulation: transaction returned with failure: Error: Client3_CAR-2029091873179 does not exist

Expected Behavior

helper.js should create all car numbers without skipping an index

Actual Behavior

helper.js skips some index as shown in the custom log below.

Client3_CAR-2029091873 is the identifier for the benchmark round. In the log below, it skips from 177 to 180

2020.08.03-13:38:05.849 debug [caliper] [helper-module]         ===HELPER-177214646 SMART CONTRACT RESULT for Client3_CAR-2029091873177== ([{"status":{"id":"9a084ba00172542152338200c4ff56237f14c29e0a9e6061253b711842221170","status":"success","time_create":1596461884963,"time_final":1596461885848,"result":null,"verified":false,"flags":0,"error_messages":[],"custom_data":{}},"result":{"type":"Buffer","data":[]},"verified":true}])
2020.08.03-13:38:06.729 debug [caliper] [helper-module]         ===HELPER1913559834 SMART CONTRACT RESULT for Client3_CAR-2029091873180== ([{"status":{"id":"5a287e1bc35d2f03d0c120325f7e39e2a7fdd83a592f09b7e99ae32560c345e0","status":"success","time_create":1596461885856,"time_final":1596461886729,"result":null,"verified":false,"flags":0,"error_messages":[],"custom_data":{}},"result":{"type":"Buffer","data":[]},"verified":true}])

here it goes from 173 to 177

2020.08.03-13:38:03.041 debug [caliper] [helper-module]         ===HELPER-177214646 SMART CONTRACT RESULT for Client1_CAR-2029091873173== ([{"status":{"id":"34f8816051947277db1edc32558f3e8a8411ed043ac357db9454ae2772e2c9df","status":"success","time_create":1596461882502,"time_final":1596461883039,"result":null,"verified":false,"flags":0,"error_messages":[],"custom_data":{}},"result":{"type":"Buffer","data":[]},"verified":true}])
2020.08.03-13:38:03.881 debug [caliper] [helper-module]         ===HELPER-177214646 SMART CONTRACT RESULT for Client1_CAR-2029091873177== ([{"status":{"id":"ab26724a3dfcc946e643f6b1fbe0f5d612303158d8718c556368282daed784b8","status":"success","time_create":1596461883452,"time_final":1596461883880,"result":null,"verified":false,"flags":0,"error_messages":[],"custom_data":{}},"result":{"type":"Buffer","data":[]},"verified":true}])

Steps to Reproduce

  1. Clone this repository https://github.com/aqidd/fabric-test-network-extended/
  2. Modify .env.example and rename to .env
  3. run ./setup-fabric-extended.sh && ./setup-caliper.sh to initialize
  4. change config.yaml in caliper/benchmarks/fabcar to larger number (e.g 300)
  5. run ./execute-caliper.sh to run the benchmark

Existing issues

I already discuss this in the rocket chat and was advised to create an issue

Your Environment

Caliper throws error for Sawtooth config

Context

Dear good people, I am trying to benchmark with sawtooth and issued the following command and getting error.

npm init -y
npm install --only=prod
@hyperledger/[email protected]
sudo npx caliper launch master
--caliper-bind-sut sawtooth:1.0.0
--caliper-workspace .
--caliper-benchconfig benchmarks/scenario/smallbank/config.yaml
--caliper-networkconfig networks/sawtooth/smallbank/sawtooth.json

Output

2020.07.07-21:49:31.929 info  [caliper] [cli-launch-master] 	Binding specification is present, performing binding for "sawtooth:1.0.0"
2020.07.07-21:49:31.938 warn  [caliper] [bind] 	Working directory not specified. Using "/home/bc/caliper/caliper-benchmarks"
2020.07.07-21:49:31.939 info  [caliper] [bind] 	Binding for [email protected]. This might take some time...
2020.07.07-21:49:31.939 info  [caliper] [bind] 	Using working directory: /home/bc/caliper/caliper-benchmarks
2020.07.07-21:49:31.939 info  [caliper] [bind] 	Calling npm with: install [email protected]
+ [email protected]
updated 1 package and audited 851 packages in 12.323s

5 packages are looking for funding
  run `npm fund` for details

found 40 vulnerabilities (36 low, 2 moderate, 2 high)
  run `npm audit fix` to fix them, or `npm audit` for details
2020.07.07-21:49:46.173 info  [caliper] [cli-launch-master] 	Set workspace path: /home/bc/caliper/caliper-benchmarks
2020.07.07-21:49:46.174 info  [caliper] [cli-launch-master] 	Set benchmark configuration path: /home/bc/caliper/caliper-benchmarks/benchmarks/scenario/smallbank/config.yaml
2020.07.07-21:49:46.174 info  [caliper] [cli-launch-master] 	Set network configuration path: /home/bc/caliper/caliper-benchmarks/networks/sawtooth/smallbank/sawtooth.json
2020.07.07-21:49:46.174 info  [caliper] [cli-launch-master] 	Set SUT type: sawtooth:1.0.0
2020.07.07-21:49:46.616 info  [caliper] [benchmark-validator] 	No observer specified, will default to `none`
Creating sawtooth-validator-default ... done
2020.07.07-21:49:46.617 info  [caliper] [caliper-utils] 	Executing command: cd .; docker-compose -f networks/sawtooth/smallbank/sawtooth-smallbank-go.yaml up -d
Creating network "smallbank_default" with the default driver
Creating sawtooth-settings-tp-default ... done
Creating sawtooth-rest-api-default ... 
Creating sawtooth-smallbank-tp-go-default ... 
Creating sawtooth-settings-tp-default ... 
2020.07.07-21:49:55.829 info  [caliper] [caliper-engine] 	Executed start command in 9.212 seconds
2020.07.07-21:49:55.830 info  [caliper] [caliper-engine] 	Executed "init" step in 0 seconds
2020.07.07-21:49:55.837 info  [caliper] [caliper-engine] 	Executed "install" step in 0 seconds
2020.07.07-21:49:55.838 info  [caliper] [messenger.js] 	Creating messenger of type "process-master" 
2020.07.07-21:49:55.854 info  [caliper] [null-observer] 	Configured "null" observer
2020.07.07-21:49:55.868 error [caliper] [round-orchestrator] 	Round 1 configuration validation error: Missing "callback" attribute
2020.07.07-21:49:55.879 error [caliper] [caliper-engine] 	Error while performing "test" step: Error: Round 1 configuration validation error: Missing "callback" attribute
2020.07.07-21:49:55.883 info  [caliper] [caliper-utils] 	Executing command: cd .; docker-compose -f networks/sawtooth/smallbank/sawtooth-smallbank-go.yaml down;(test -z "$(docker ps -aq)") || docker rm $(docker ps -aq)
Stopping sawtooth-settings-tp-default     ... done
Stopping sawtooth-smallbank-tp-go-default ... done
Stopping sawtooth-rest-api-default        ... done
Stopping sawtooth-validator-default       ... done
Removing sawtooth-settings-tp-default     ... done
Removing sawtooth-smallbank-tp-go-default ... done
Removing sawtooth-rest-api-default        ... done
Removing sawtooth-validator-default       ... done
Removing network smallbank_default
2020.07.07-21:50:19.469 info  [caliper] [caliper-engine] 	Executed end command in 23.585 seconds
2020.07.07-21:50:19.469 error [caliper] [cli-launch-master] 	Benchmark failed with error code 6
Usage:
 caliper launch master --caliper-bind-sut fabric:1.4.1 [other options]

Options:
  --help, -h           Show usage information  [boolean]
  --version            Show version information  [boolean]
  --caliper-bind-sut   The name and version of the platform to bind to  [string]
  --caliper-bind-cwd   The working directory for performing the SDK install  [string]
  --caliper-bind-args  Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter  [string]
  --caliper-bind-file  Yaml file to override default (supported) package versions when binding an SDK  [string]

Error: Benchmark failed with error code 6
    at Function.handler (/home/bc/caliper/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/launch/lib/launchMaster.js:70:23)
    at process._tickCallback (internal/process/next_tick.js:68:7)

My Environment

  • Version used: Caliper 0.3.2, Sawtooth 1.0.0
  • Environment name and version: NodeJS 10.21.0, npm 6.14.4
  • Operating System and version (desktop): Ubuntu 16.04

Please kindly help me to resolve this.

Unable to start the Grafana docker container

Following error is present in Grafana logs

t=2019-10-21T09:31:54+0000 lvl=eror msg="Can't read alert notification provisioning files from directory" logger=provisioning.notifiers path=/etc/grafana/provisioning/notifiers error="open /etc/grafana/provisioning/notifiers: no such file or directory"
t=2019-10-21T09:31:54+0000 lvl=eror msg="Server shutdown" logger=server reason="Service init failed: Failed to create provisioner: Failed to read dashboards config: could not parse provisioning config file: docker-and-system.yaml error: yaml: unmarshal errors:\n  line 1: cannot unmarshal !!map into []*dashboards.DashboardsAsConfigV0"

Travis CI is no longer supported

Travis CI has changed how open source projects are supported, and Hyperledger can no longer build there. I suggest Azure Pipelines or GitHub Actions as a replacement.

pem file not fonud

Caliper benchmarks "/networks/fabric/fabric-v1.4.1/2org1peergoleveldb_raft/fabric-go-tls.yaml" need
"
organizations:
Org1:
mspid: Org1MSP
peers:
- peer1.org1.example.com
adminPrivateKey:
path: networks/fabric/config_raft/crypto-config/peerOrganizations/org1.example.com/users/[email protected]/msp/keystore/key.pem

"
but fabric1.4.4 generated file does not have it, only one key "65c2644c9f91e1366a7f6185755abd6de10aecb89d6353e8352772d1c158ae42_sk", what to do

Error running benchmark on version 0.4.0 | Ethereum

Hello, I am trying to run the simple scenario example on the Ethereum, but facing the following errors

2020.10.18-04:27:11.799 error [caliper] [round-orchestrator]    Failed round 1 (open): Error: Error: Module "/Users/fbalwy/Desktop/caliper-benchmarks-0.4.0 3/benchmarks/scenario/simple/open.js" could not be loaded: TypeError: Class extends value #<Object> is not a constructor or null

2020.10.18-04:27:11.808 error [caliper] [round-orchestrator]    Failed round 2 (query): Error: Error: Module "/Users/fbalwy/Desktop/caliper-benchmarks-0.4.0 3/benchmarks/scenario/simple/query.js" could not be loaded: TypeError: Class extends value #<Object> is not a constructor or null

2020.10.18-04:27:11.818 error [caliper] [round-orchestrator]    Failed round 3 (transfer): Error: Error: Module "/Users/fbalwy/Desktop/caliper-benchmarks-0.4.0 3/benchmarks/scenario/simple/transfer.js" could not be loaded: TypeError: Class extends value #<Object> is not a constructor or null

2020.10.18-04:27:11.819 error [caliper] [report-builder]        No data within test result; implies error within configuration files
2020.10.18-04:27:11.819 error [caliper] [round-orchestrator]    Error while finalizing the report: Error: unrecognized report table
    at ReportBuilder.setSummaryTable (/usr/local/lib/node_modules/@hyperledger/caliper-cli/node_modules/@hyperledger/caliper-core/lib/manager/report/report-builder.js:142:19)

I have only changed the networkconfig.json to be able to run the benchmark on local Ethereum network

{
    "caliper": {
        "blockchain": "ethereum"
    },
    "ethereum": {
        "url": "ws://localhost:8545",
        "contractDeployerAddress": "0xB4422fD3450Fcff1190861ECAacc1cfB01008A9e",
        "contractDeployerAddressPrivateKey": "d16becb442ff55c43a24d6e28f4b7cf3cd6786c90e95afe73d74e4e2c18965ff",
        "fromAddress": "0xB4422fD3450Fcff1190861ECAacc1cfB01008A9e",
        "fromAddressPrivateKey": "d16becb442ff55c43a24d6e28f4b7cf3cd6786c90e95afe73d74e4e2c18965ff",

        "transactionConfirmationBlocks": 2,
        "contracts": {
            "simple": {
                "path": "./src/ethereum/simple/simple.json",
                "estimateGas": true,
                "gas": {
                    "query": 100000,
                    "transfer": 70000
                }
            }
        }
    }
}

unable to invoke js chaincode and cannot use peer command outside the CLI

I am working on hyperledger fabric 2.3

Whenever I try to deploy chaincode in javascript I get the problem while invoking it and I am also not able to use peer command outside the cli.

ubuntu@ip-172-31-18-117:~/fabric-samples/test-network$ export PATH=${PWD}/../bin:$PATH

ubuntu@ip-172-31-18-117:~/fabric-samples/test-network$ export FABRIC_CFG_PATH=$PWD/../config/

ubuntu@ip-172-31-18-117:~/fabric-samples/test-network$ peer chaincode invoke -o orderer.example.com:7050 --tls --cafile ${PWD}/organizations/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem -C mychannel -n mycc --peerAddresses peer0.org1.example.com:7051 --tlsRootCertFiles ${PWD}/organizations/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/tls/ca.crt --peerAddresses peer0.org2.example.com:9051 --tlsRootCertFiles ${PWD}/organizations/peerOrganizations/org2.example.com/peers/peer0.org2.example.com/tls/ca.crt --isInit -c '{"function":"InitLedger","Args":[]}'

then I got the error:

Error: 2021-03-16 13:36:52.033 UTC [main] InitCmd -> ERRO 001 Cannot run peer because cannot init crypto, specified path "/home/ubuntu/fabric-samples/config/msp" does not exist or cannot be accessed: stat /home/ubuntu/fabric-samples/config/msp: no such file or directory

please do help

I am stuck with this for a long time

and when I try to invoke chaincode from CLI then it gives an error

Error:

> 2021-03-16 13:34:14.062 UTC [chaincodeCmd] chaincodeInvokeOrQuery -> DEBU 05f ESCC invoke result: response:<status:500 message:"error in simulation: failed to execute transaction ab91db0d7cfd1486060dd4eda3433a795420a586a22bb9be2b840d0c4991cadc: could not launch chaincode myccv1:ef37e8fd88cd288ac9fc1cc7a03584c798a8ee7577b6aac20d6c6722009dc631: error starting container: error starting container: API error (500): Could not attach to network test: rpc error: code = NotFound desc = network test not found" > Error: endorsement failure during invoke. response: status:500 message:"error in simulation: failed to execute transaction ab91db0d7cfd1486060dd4eda3433a795420a586a22bb9be2b840d0c4991cadc: could not launch chaincode myccv1:ef37e8fd88cd288ac9fc1cc7a03584c798a8ee7577b6aac20d6c6722009dc631: error starting container: error starting container: API error (500): Could not attach to network test: rpc error: code = NotFound desc = network test not found"

2org1peergoleveldb_kafka [caliper-flow] : Error: Couldn't create Channel 'mychannel'

I was running the test benchmark on 2org1peergoleveldb_kafka/docker-compose.yaml configurations. Here's how I ran the benchmark.

npx caliper benchmark run --caliper-benchconfig benchmarks/samples/fabric/marbles/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.0/2org1peergoleveldb_kafka/fabric-node.yaml --caliper-workspace ./

Error

error [caliper] [caliper-flow] 	Error: Error: Couldn't create Channel 'mychannel': Orderer response indicated unsuccessful Channel 'mychannel' creation: SERVICE_UNAVAILABLE
    at Fabric._createChannels (/root/benchmarks/caliper-benchmarks/node_modules/@hyperledger/caliper-fabric/lib/fabric.js:352:23)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7)

I was using the network configuration as it is in the config_kafka. I'm not sure whether this is a bug or something I'm not doing correctly.

Failed to pull Hyperledger Fabric binaries

Running generate.sh in networks/fabric/config_solo results in following error;

mrx@devbox:~/code/caliper-benchmarks/networks/fabric/config_solo$ ./generate.sh 

Pull Hyperledger Fabric binaries

===> Downloading version x86_64-1.0.0 platform specific fabric binaries
===> Downloading:  https://github.com/hyperledger/fabric/releases/download/v1.0.0/hyperledger-fabric-linux-amd64-1.0.0.tar.gz
--2020-01-08 17:31:58--  https://github.com/hyperledger/fabric/releases/download/v1.0.0/hyperledger-fabric-linux-amd64-1.0.0.tar.gz
Resolving github.com (github.com)... 140.82.118.4
Connecting to github.com (github.com)|140.82.118.4|:443... connected.
HTTP request sent, awaiting response... 404 Not Found
2020-01-08 17:31:58 ERROR 404: Not Found.

tar (child): hyperledger-fabric-linux-amd64-1.0.0.tar.gz: Cannot open: No such file or directory
tar (child): Error is not recoverable: exiting now
tar: Child returned status 2
tar: Error is not recoverable: exiting now
rm: cannot remove 'hyperledger-fabric-linux-amd64-1.0.0.tar.gz': No such file or directory
==> There was an error downloading the binary file.

------> x86_64-1.0.0 platform specific fabric binary is not available to download <----

./generate.sh: line 13: ./bin/cryptogen: No such file or directory
./generate.sh: line 14: ./bin/configtxgen: No such file or directory
./generate.sh: line 15: ./bin/configtxgen: No such file or directory
find: ‘crypto-config’: No such file or directory

Error: Unknown "fabric" SDK version "1.4.0"

Hello, I'm trying to install caliper , when I come to this step(npx caliper bind
--caliper-bind-sut fabric:1.4.0) I got this error below
( I'm using: Ubuntu 20.04
Fabric v1.4.0
nodejs v10.14.1
npm 6.13.4
docker 19.03.8& docker-compose v1.25.0)

2020.12.30-16:57:19.347 error [caliper] [bind] Unknown "fabric" SDK version "1.4.0"
Usage:
caliper bind --caliper-bind-sut fabric:1.4 --caliper-bind-cwd ./ --caliper-bind-args="-g"

Options:
--help, -h Show usage information [boolean]
--version Show version information [boolean]
--caliper-bind-sut The name and version of the platform and its SDK to bind to [string]
--caliper-bind-cwd The working directory for performing the SDK install [string]
--caliper-bind-args Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter [string]
--caliper-bind-file Yaml file to override default (supported) package versions when binding an SDK [string]

Error: Unknown "fabric" SDK version "1.4.0"
at Function.handler (/home/humeyra/Documents/node_modules/@hyperledger/caliper-cli/lib/lib/bindCommon.js:89:19)
at Object.module.exports.handler (/home/humeyra/Documents/node_modules/@hyperledger/caliper-cli/lib/bindCommand.js:49:41)

at Object.runCommand (/home/humeyra/Documents/node_modules/yargs/lib/command.js:240:40)
at Object.parseArgs [as _parseArgs] (/home/humeyra/Documents/node_modules/yargs/yargs.js:1154:41)
at Object.get [as argv] (/home/humeyra/Documents/node_modules/yargs/yargs.js:1088:21)
at Object.<anonymous> (/home/humeyra/Documents/node_modules/@hyperledger/caliper-cli/caliper.js:39:5)
at Module._compile (internal/modules/cjs/loader.js:688:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:699:10)
at Module.load (internal/modules/cjs/loader.js:598:32)
at tryModuleLoad (internal/modules/cjs/loader.js:537:12)

can anyone help me how can i solve it even, I try all the version of Fabric but nothing change?

error: [FabricCAClientService.js]: Failed to enroll admin, error:%o message=Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054], stack=Error: Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054]

I am installing hyperledger caliber using the local NPM found at https://hyperledger.github.io/caliper/v0.3/installing-caliper/.
But I invoke the local CLI binary (step 4) using the command,

npx caliper launch master --caliper-workspace . --caliper-benchconfig benchmarks/scenario/simple/config.yaml --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peergoleveldb/fabric-go.yaml

my steps:

  1. git clone https://github.com/hyperledger/caliper-benchmarks.git
  2. cd caliper-benchmarks
  3. git checkout v0.3.0
  4. npm init -y
    npm install --only=prod
    @hyperledger/[email protected]
    npx caliper launch master
    --caliper-bind-sut fabric:1.4.0
    --caliper-workspace .
    --caliper-benchconfig benchmarks/scenario/simple/config.yaml
    --caliper-networkconfig networks/fabric/fabric-v1.4.1/2org1peergoleveldb/fabric-go.yaml

I got the following log error:
2020.09.27-19:21:09.329 info [caliper] [cli-launch-master] Set workspace path: /home/qwe/caliper-benchmarks
2020.09.27-19:21:09.330 info [caliper] [cli-launch-master] Set benchmark configuration path: /home/qwe/caliper-benchmarks/benchmarks/scenario/simple/config.yaml
2020.09.27-19:21:09.331 info [caliper] [cli-launch-master] Set network configuration path: /home/qwe/caliper-benchmarks/networks/fabric/fabric-v1.4.1/2org1peergoleveldb/fabric-go.yaml
2020.09.27-19:21:09.331 info [caliper] [cli-launch-master] Set SUT type: fabric
2020.09.27-19:21:09.334 info [caliper] [benchmark-validator] No observer specified, will default to none
2020.09.27-19:21:09.334 info [caliper] [caliper-engine] Starting benchmark flow
2020.09.27-19:21:09.339 info [caliper] [adapters/fabric] Initializing standard adaptor compatible with installed SDK: 1.4.0
2020.09.27-19:21:09.826 info [caliper] [caliper-utils] Executing command: cd .; export FABRIC_VERSION=1.4.1;export FABRIC_CA_VERSION=1.4.1;docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb/docker-compose.yaml up -d;sleep 3s
Couldn't connect to Docker daemon at http+docker://localunixsocket - is it running?

If it's at a non-standard location, specify the URL with the DOCKER_HOST environment variable.
2020.09.27-19:21:13.466 info [caliper] [caliper-engine] Executed start command in 3.64 seconds
2020.09.27-19:21:13.466 info [caliper] [adapters/fabric] Fabric SDK version: 1.4.0; TLS: none
2020-09-28T02:21:13.871Z - error: [FabricCAClientService.js]: Failed to enroll admin, error:%o message=Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054], stack=Error: Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054]
at ClientRequest.request.on (/home/qwe/caliper-benchmarks/node_modules/fabric-ca-client/lib/FabricCAClient.js:487:12)
at ClientRequest.emit (events.js:189:13)
at Socket.socketErrorListener (_http_client.js:392:9)
at Socket.emit (events.js:189:13)
at emitErrorNT (internal/streams/destroy.js:82:8)
at emitErrorAndCloseNT (internal/streams/destroy.js:50:3)
at process._tickCallback (internal/process/next_tick.js:63:19)
2020.09.27-19:21:13.873 error [caliper] [caliper-engine] Error while performing "init" step: Error: Couldn't enroll Org1's registrar or set it as user context: Calling enrollment endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054]
2020.09.27-19:21:13.873 info [caliper] [caliper-engine] Executed "init" step in 0.407 seconds
2020.09.27-19:21:13.873 info [caliper] [caliper-utils] Executing command: cd .; docker-compose -f networks/fabric/docker-compose/2org1peergoleveldb/docker-compose.yaml down;(test -z "$(docker ps -aq)") || docker rm $(docker ps -aq);(test -z "$(docker images dev* -q)") || docker rmi $(docker images dev* -q);rm -rf /tmp/hfc-*
The FABRIC_VERSION variable is not set. Defaulting to a blank string.
The FABRIC_CA_VERSION variable is not set. Defaulting to a blank string.
Couldn't connect to Docker daemon at http+docker://localunixsocket - is it running?

If it's at a non-standard location, specify the URL with the DOCKER_HOST environment variable.
Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.40/containers/json?all=1: dial unix /var/run/docker.sock: connect: permission denied
Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.40/containers/json?all=1: dial unix /var/run/docker.sock: connect: permission denied
"docker rm" requires at least 1 argument.
See 'docker rm --help'.

Usage: docker rm [OPTIONS] CONTAINER [CONTAINER...]

Remove one or more containers
Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.40/images/json?filters=%7B%22reference%22%3A%7B%22dev%2A%22%3Atrue%7D%7D: dial unix /var/run/docker.sock: connect: permission denied
Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.40/images/json?filters=%7B%22reference%22%3A%7B%22dev%2A%22%3Atrue%7D%7D: dial unix /var/run/docker.sock: connect: permission denied
"docker rmi" requires at least 1 argument.
See 'docker rmi --help'.

Usage: docker rmi [OPTIONS] IMAGE [IMAGE...]

Remove one or more images
2020.09.27-19:21:14.800 info [caliper] [caliper-engine] Executed end command in 0.927 seconds
2020.09.27-19:21:14.801 error [caliper] [cli-launch-master] Benchmark failed with error code 4
Usage:
caliper launch master --caliper-bind-sut fabric:1.4.1 [other options]

选项:
--help, -h Show usage information [布尔]
--version Show version information [布尔]
--caliper-bind-sut The name and version of the platform to bind to [字符串]
--caliper-bind-cwd The working directory for performing the SDK install [字符串]
--caliper-bind-args Additional arguments to pass to "npm install". Use the "=" notation when setting this parameter [字符串]
--caliper-bind-file Yaml file to override default (supported) package versions when binding an SDK [字符串]

Error: Benchmark failed with error code 4
at Function.handler (/home/qwe/caliper-benchmarks/node_modules/@hyperledger/caliper-cli/lib/launch/lib/launchMaster.js:70:23)
at process._tickCallback (internal/process/next_tick.js:68:7)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.