我正在使用 Hyperledger Caliper 0.4.2 对部署在 Docker Swarm 集群上的 Hyperldger Fabric 2.1.0 网络进行基准测试。Fabric 网络已启动并运行,所有链码均已正确安装和启动。Caliper 基准是 dockerized,我在同一个 Docker 网络上运行它。但是,当我启动容器时,它会在注册所有客户端后挂起,如下面的日志所示。
caliper_2.2 | 2021.04.17-14:45:21.445 info [caliper] [cli-launch-manager] Binding specification is present, performing binding for "fabric:2.1.0"
caliper_2.2 | 2021.04.17-14:45:21.448 warn [caliper] [bind] Working directory not specified. Using "/hyperledger/caliper/workspace"
caliper_2.2 | 2021.04.17-14:45:21.448 info [caliper] [bind] User-provided arguments for npm: "-g"
caliper_2.2 | 2021.04.17-14:45:21.448 info [caliper] [bind] Binding for fabric@2.1.0. This might take some time...
caliper_2.2 | 2021.04.17-14:45:21.448 info [caliper] [bind] Using working directory: /hyperledger/caliper/workspace
caliper_2.2 | 2021.04.17-14:45:21.449 info [caliper] [bind] Calling npm with: install -g fabric-common@2.1.0 fabric-protos@2.1.0 fabric-network@2.1.0 fabric-ca-client@2.1.0
caliper_2.2 | npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
caliper_2.2 | npm WARN deprecated har-validator@5.1.5: this library is no longer supported
caliper_2.2 | + fabric-protos@2.1.0
caliper_2.2 | + fabric-network@2.1.0
caliper_2.2 | + fabric-common@2.1.0
caliper_2.2 | + fabric-ca-client@2.1.0
caliper_2.2 | updated 4 packages in 5.591s
caliper_2.2 | 2021.04.17-14:45:27.588 info [caliper] [cli-launch-manager] Set workspace path: /hyperledger/caliper/workspace
caliper_2.2 | 2021.04.17-14:45:27.589 info [caliper] [cli-launch-manager] Set benchmark configuration path: /hyperledger/caliper/workspace/scenarios/config.yaml
caliper_2.2 | 2021.04.17-14:45:27.589 info [caliper] [cli-launch-manager] Set network configuration path: /hyperledger/caliper/workspace/networks/fabric/network-config3.yaml
caliper_2.2 | 2021.04.17-14:45:27.589 info [caliper] [cli-launch-manager] Set SUT type: fabric
caliper_2.2 | 2021.04.17-14:45:27.631 info [caliper] [benchmark-validator] No observer specified, will default to `none`
caliper_2.2 | 2021.04.17-14:45:27.631 info [caliper] [caliper-engine] Starting benchmark flow
caliper_2.2 | 2021.04.17-14:45:28.154 info [caliper] [fabric-connector] Initializing gateway connector compatible with installed SDK: 2.1.0
caliper_2.2 | 2021.04.17-14:45:28.586 info [caliper] [caliper-engine] Network configuration attribute "caliper.command.start" is not present, skipping start command
caliper_2.2 | 2021.04.17-14:45:28.586 info [caliper] [connectors/v2/fabric-gateway] Fabric SDK version: 2.1.0; TLS: server
caliper_2.2 | 2021.04.17-14:45:28.587 warn [caliper] [connectors/v2/fabric-gateway] Administrative actions are not possible with Fabric SDK version: 2.1.0
caliper_2.2 | 2021.04.17-14:45:28.587 info [caliper] [connectors/v2/fabric-gateway] Fabric SDK version: 2.1.0; TLS: server
caliper_2.2 | 2021.04.17-14:45:28.587 info [caliper] [connectors/v2/fabric-gateway] Creating new InMemoryWallets for organizations
caliper_2.2 | 2021.04.17-14:45:28.588 info [caliper] [connectors/v2/fabric-gateway] Initializing administrators
caliper_2.2 | 2021.04.17-14:45:28.588 info [caliper] [connectors/v2/fabric-gateway] No admin.Org1 found in caliper configuration file - unable to perform admin options
caliper_2.2 | 2021.04.17-14:45:28.588 info [caliper] [connectors/v2/fabric-gateway] No admin.Org2 found in caliper configuration file - unable to perform admin options
caliper_2.2 | 2021.04.17-14:45:28.588 info [caliper] [connectors/v2/fabric-gateway] No admin.Org3 found in caliper configuration file - unable to perform admin options
caliper_2.2 | 2021.04.17-14:45:28.589 info [caliper] [connectors/v2/fabric-gateway] No admin.Org4 found in caliper configuration file - unable to perform admin options
caliper_2.2 | 2021.04.17-14:45:28.589 info [caliper] [connectors/v2/fabric-gateway] No admin.Org5 found in caliper configuration file - unable to perform admin options
caliper_2.2 | 2021.04.17-14:45:28.589 info [caliper] [connectors/v2/fabric-gateway] Completed initializing administrators
caliper_2.2 | 2021.04.17-14:45:29.946 info [caliper] [connectors/v2/fabric-gateway] Initializing users
caliper_2.2 | 2021.04.17-14:45:29.947 info [caliper] [connectors/v2/fabric-gateway] Client client0.org1.digiblocks.com being initialized using provided crypto content
caliper_2.2 | 2021.04.17-14:45:29.947 info [caliper] [connectors/v2/fabric-gateway] Adding identity for name client0.org1.digiblocks.com to wallet for organization Org1
caliper_2.2 | 2021.04.17-14:45:29.947 info [caliper] [connectors/v2/fabric-gateway] Identity client0.org1.digiblocks.com created and imported to wallet
caliper_2.2 | 2021.04.17-14:45:29.947 info [caliper] [connectors/v2/fabric-gateway] Client client0.org2.digiblocks.com being initialized using provided crypto content
caliper_2.2 | 2021.04.17-14:45:29.948 info [caliper] [connectors/v2/fabric-gateway] Adding identity for name client0.org2.digiblocks.com to wallet for organization Org2
caliper_2.2 | 2021.04.17-14:45:29.948 info [caliper] [connectors/v2/fabric-gateway] Identity client0.org2.digiblocks.com created and imported to wallet
caliper_2.2 | 2021.04.17-14:45:29.948 info [caliper] [connectors/v2/fabric-gateway] Client client0.org3.digiblocks.com being initialized using provided crypto content
caliper_2.2 | 2021.04.17-14:45:29.948 info [caliper] [connectors/v2/fabric-gateway] Adding identity for name client0.org3.digiblocks.com to wallet for organization Org3
caliper_2.2 | 2021.04.17-14:45:29.948 info [caliper] [connectors/v2/fabric-gateway] Identity client0.org3.digiblocks.com created and imported to wallet
caliper_2.2 | 2021.04.17-14:45:29.948 info [caliper] [connectors/v2/fabric-gateway] Client client0.org4.digiblocks.com being initialized using provided crypto content
caliper_2.2 | 2021.04.17-14:45:29.949 info [caliper] [connectors/v2/fabric-gateway] Adding identity for name client0.org4.digiblocks.com to wallet for organization Org4
caliper_2.2 | 2021.04.17-14:45:29.949 info [caliper] [connectors/v2/fabric-gateway] Identity client0.org4.digiblocks.com created and imported to wallet
caliper_2.2 | 2021.04.17-14:45:29.949 info [caliper] [connectors/v2/fabric-gateway] Client client0.org5.digiblocks.com being initialized using provided crypto content
caliper_2.2 | 2021.04.17-14:45:29.949 info [caliper] [connectors/v2/fabric-gateway] Adding identity for name client0.org5.digiblocks.com to wallet for organization Org5
caliper_2.2 | 2021.04.17-14:45:29.949 info [caliper] [connectors/v2/fabric-gateway] Identity client0.org5.digiblocks.com created and imported to wallet
caliper_2.2 | 2021.04.17-14:45:29.949 info [caliper] [connectors/v2/fabric-gateway] Completed initializing users
caliper_2.2 | 2021.04.17-14:45:29.949 info [caliper] [caliper-engine] Executed "init" step in 1.363 seconds
caliper_2.2 | 2021.04.17-14:45:29.950 warn [caliper] [connectors/v2/fabric-gateway] Install smart contract not available with Fabric SDK version: 2.1.0
caliper_2.2 | 2021.04.17-14:45:29.950 info [caliper] [caliper-engine] Executed "install" step in 0 seconds
caliper_2.2 | 2021.04.17-14:45:29.952 info [caliper] [monitor.js] Attempting to create resource monitor of type docker
caliper_2.2 | 2021.04.17-14:45:29.954 info [caliper] [default-observer] Observer interval set to 5000 seconds
caliper_2.2 | 2021.04.17-14:45:29.955 info [caliper] [round-orchestrator] Preparing worker connections
caliper_2.2 | 2021.04.17-14:45:29.956 info [caliper] [worker-orchestrator] Launching worker 1 of 1
caliper_2.2 | 2021.04.17-14:45:29.962 info [caliper] [worker-orchestrator] Messenger not configured, entering configure phase...
caliper_2.2 | 2021.04.17-14:45:29.962 info [caliper] [worker-orchestrator] No existing workers detected, entering worker launch phase...
caliper_2.2 | 2021.04.17-14:45:29.963 info [caliper] [worker-orchestrator] Waiting for 1 workers to be connected...
caliper_2.2 | 2021.04.17-14:45:30.387 info [caliper] [cli-launch-worker] Worker is a locally forked process, skipping binding step already performed by the manager process
caliper_2.2 | 2021.04.17-14:45:30.389 info [caliper] [cli-launch-worker] Set workspace path: /hyperledger/caliper/workspace
caliper_2.2 | 2021.04.17-14:45:30.389 info [caliper] [cli-launch-worker] Set benchmark configuration path: /hyperledger/caliper/workspace/scenarios/config.yaml
caliper_2.2 | 2021.04.17-14:45:30.389 info [caliper] [cli-launch-worker] Set network configuration path: /hyperledger/caliper/workspace/networks/fabric/network-config3.yaml
caliper_2.2 | 2021.04.17-14:45:30.389 info [caliper] [cli-launch-worker] Set SUT type: fabric
caliper_2.2 exited with code 0
奇怪的是它没有输出任何错误。以下是 Caliper 的 Docker-Compose 文件
version: "3"
networks:
caliper-overlay:
external:
name: caliper-overlay
services:
caliper_2_2:
container_name: caliper_2.2
image: hyperledger/caliper:0.4.2
command: launch manager --caliper-fabric-gateway-enabled --caliper-fabric-gateway-localhost=false
environment:
- CALIPER_BIND_SUT=fabric:2.1.0
- CALIPER_BENCHCONFIG=scenarios/config.yaml
- CALIPER_NETWORKCONFIG=networks/fabric/network-config3.yaml
volumes:
- ./:/hyperledger/caliper/workspace
networks:
caliper-overlay:
aliases:
- caliper.digiblocks.com
任何调试此问题的见解将不胜感激。