Git Product home page Git Product logo

ethereum-benchmark's Introduction

Ethereum-Benchmark

A collection of utilities for creating & benchmarking private Ethereum network

Getting started

Prerequisites

You need standard Geth installation to get started.
In Debian/Ubuntu, you can run the following command to install required toolset:

sudo add-apt-repository -y ppa:ethereum/ethereum
sudo apt-get update
sudo apt-get install ethereum

Ethereum-benchmark has been tested against Geth version 1.8.18 on Ubuntu 18.04.

Installation

Clone this repository by doing

git clone https://github.com/puilp0502/ethereum-benchmark

Deploying network

First, create the bootnode's key:

bootnode -genkey boot.key

Then, generate node keys:

./gennodekey.sh [number of nodes]

Create genesis config using puppeth:

puppeth

Puppeth will ask you a few questions. Answer them as you like.
Note that Ethereum-benchmark expects network id of 1515. If you change this, you need to manually change node startup script(start_node*.sh). It also expects genesis config to be located at genesis.json.

Now, initialize your nodes:

./initnode.sh

If everying is completed without error, you should be able to start nodes now.
First, start bootnode:

./start_bootnode.sh

Then, in the other terminal(s), start nodes by doing:

./start_node[number].sh

The nodes should be up and mining that sweet sweet blocks.

Running benchmark

cd benchmark
npm install
node index.js

Benchmark result will be stored in results/ directory.

License

This utility is licensed under MIT License - see LICENSE file for details.

Acknowledgements

This utility is originally based on the post written by Salanfe.

ethereum-benchmark's People

Contributors

puilp0502 avatar

Watchers

 avatar  avatar

ethereum-benchmark's Issues

Can't install benchmark

When I deploy the node index.js the system reply with:

`Connecting to local RPC...
Connected
internal/modules/cjs/loader.js:613
throw err;
^

Error: Cannot find module 'glob'
Require stack:

  • /home/ubuntu/ethereum-benchmark/benchmark/wallet.js
  • /home/ubuntu/ethereum-benchmark/benchmark/index.js
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:610:15)
    at Function.Module._load (internal/modules/cjs/loader.js:526:27)
    at Module.require (internal/modules/cjs/loader.js:666:19)
    at require (internal/modules/cjs/helpers.js:16:16)
    at Object. (/home/ubuntu/ethereum-benchmark/benchmark/wallet.js:2:14)
    at Module._compile (internal/modules/cjs/loader.js:759:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:770:10)
    at Module.load (internal/modules/cjs/loader.js:628:32)
    at Function.Module._load (internal/modules/cjs/loader.js:555:12)
    at Module.require (internal/modules/cjs/loader.js:666:19)`

Any idea? I tried to uninstall and reinstall node, npm etc but still doesn't work..

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.