Skip to main content
Share Your Experience: Take the 2024 Developer Survey
92 votes
Accepted

What does each genesis.json parameter mean?

Genesis block Explanation mixhash A 256-bit hash which proves, combined with the nonce, that a sufficient amount of computation has been carried out on this block: the Proof-of-Work (PoW). The ...
niksmac's user avatar
  • 9,673
76 votes

How do I set up a private ethereum network?

Creating a private testnet for Ethereum is actually pretty easy. In recent versions of geth, you don't even need to create your own genesis block, or any other complicated steps (many of the online ...
Adrian Macneil's user avatar
36 votes
Accepted

What is a chainID in Ethereum, how is it different than NetworkID, and how is it used?

How is it different than networkID? ChainID was introduced in EIP-155 to prevent replay attacks between the main ETH and ETC chains, which both have a networkID of 1. It's basically just an ...
Richard Horrocks's user avatar
34 votes
Accepted

Difference between Ganache and Truffle

Ganache allows you to create a private Ethereum blockchain for you to run tests, execute commands, and inspect state while controlling how the chain operates. It gives you the ability to perform all ...
Shane Fontaine's user avatar
24 votes

How to decode input data from a transaction?

If you've heard about the ethers js library, it provides a fantastic function named parseTransaction, I found it after a very long search as it wasn't mentioned in any online forums and I'm still ...
Achal Singh's user avatar
23 votes
Accepted

How to decode input data from a transaction?

You can do web3.toAscii(transactionID.input) to return the data in readable format. Read web3.toAscii
niksmac's user avatar
  • 9,673
23 votes
Accepted

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

Answer is to update genesis.json to include eip150Block: { "config": { "chainId": 4777, "homesteadBlock": 0, "eip150Block": 0, "eip155Block": 0, "eip158Block"...
Leon Africa's user avatar
22 votes

How to decode input data from a transaction?

In order to decode data you can use a library called abi-decoder You will need to provide an ABI for the smart contract you want to decode, then just paste the input data. Very simple. The only ...
Moe Elsharif's user avatar
19 votes

What is a sidechain?

Sidechain is a blockchain that runs in parallel to the main blockchain which extends functionality through interoperable blockchain networks allowing a decentralized way of transferring/synchronizing ...
kenorb's user avatar
  • 1,171
19 votes

How to set up a Private network and connect peers in geth?

Setting up genesis block: The first block (block zero) of the block chain is called as the genesis block. This is the only block on the network that doesn't point to the predecessor block. By default ...
Parthasarathy Ramanujam's user avatar
19 votes

What is an HD wallet for Ether and how to create one using node.js?

HD Wallets refer to Hierarchical Deterministic wallets. They are wallets that, from a root, can generate multiple "child" private keys in a deterministic way. You only need to remember the &...
Ismael's user avatar
  • 30.5k
18 votes

Block explorer running on private network

I don't know of any block explorer source code / application you can deploy into your private network. Here's my scripts to check and print blocks, uncles and transactions that can be used to ...
BokkyPooBah's user avatar
  • 40.3k
16 votes

How do I set up a private ethereum network?

If you are just testing contracts I would recommend using a lightweight Ethereum node like https://github.com/trufflesuite/ganache-cli. This way getting your network set up is as simple as running: ...
Karl Floersch's user avatar
16 votes
Accepted

Deploying the Greeter contract via the geth CLI is not registering in my private blockchain

Update Apr 23 2017 geth 1.6.0 has a breaking change to remove access to the Solidity compiler from within geth. The workaround is detailed in How to compile Solidity contracts within geth with the ...
BokkyPooBah's user avatar
  • 40.3k
16 votes
Accepted

How to make Ethereum mining difficulty static for a private chain?

Modify the CalcDifficulty in Geth to return a static number, then rebuild Geth. Example: func CalcDifficulty(config *ChainConfig, time, parentTime uint64, parentNumber, parentDiff *big.Int) *big.Int ...
eth's user avatar
  • 85.9k
16 votes

getting error on max invalid genesis file: hex string has odd length

I had the same problem and found that the issue was: "extraData": "0x0", If you change it to: "extraData": "0x00", The problem goes away. At this point though you'll have another issue because ...
Brad Lucas's user avatar
15 votes
Accepted

Running a custom private go-ethereum node cluster using docker

Summary Check that there is network connectivity between the two Docker containers and reconfigure if necessary. Check there is sufficient memory allocated to each container. In each Docker container ...
BokkyPooBah's user avatar
  • 40.3k
15 votes
Accepted

What is the safest minimum block time to use without having any problem on Proof-of-Authority consensus?

PoA in Aura consensus engine of parity defaults to 5s, which has been tested to run with good stability. PoA network runs one such infrastructure. I have tested for a 1 sec PoA using aura running ...
Ayushya's user avatar
  • 1,698
14 votes

What does each genesis.json parameter mean?

In addition to the fields described by niksmac: config Configuration to describe the chain itself. Specifically the chain ID, the consensus engines to use, as well as the block numbers of any ...
Richard Horrocks's user avatar
14 votes

Is it possible to change the block target time?

The block times in a private network and the public network is determined by the block difficulty adjustment algorithm. This algorithm is fixed in code, and is examined in more detail in How does the ...
BokkyPooBah's user avatar
  • 40.3k
14 votes
Accepted

How to deploy smart contract in predefined contract address in private ethereum network?

It is not possible to deploy a contract to an address of your choice The address a contract is deployed to is generated deterministically using the address of the deployer and the deployer's total ...
Joe's user avatar
  • 1,173
13 votes

How to decode input data from a transaction?

UI Tools cleanunicorn.github.io/santoku etid.wtd.ru ethtx.info moesif.com/solidity-abi-hex-decoder/decode Note for these you will need the ABI of the contract. Node Packages @ethersproject/abi (...
Paul Razvan Berg's user avatar
12 votes
Accepted

How many transactions are there in a block?

The following is a simplified explanation of what geth does. There are two main places where transactions can be: in a block, or in the transaction pool (txpool). When a node first hears about a ...
Matthew Schmidt's user avatar
11 votes

What does it mean to "seal a block"?

"Seal a block" is a proposed term to describe "mine a block" in a private chain. Private chains typically do not need to use proof-of-work mining, so a different term can be helpful. Specifics of ...
eth's user avatar
  • 85.9k
11 votes
Accepted

Geth --rpcaddr doubt

--rpcaddr 127.0.0.1 starts the JSON RCP on the localhost network and only connections from your local machine reach the geth server --rpcaddr 0.0.0.0 starts the JSON RPC on all interfaces and any ...
Daniel Luca CleanUnicorn's user avatar
11 votes
Accepted

Block time and confirmation time

Block time is the expected interval between two blocks. For ethereum, this is around 15 seconds. For Bitcoin, it is 10 minutes. The number of confirmations is simply the number of blocks that have ...
Raghav Sood's user avatar
  • 4,050
10 votes

Out of Gas invoking precompiled contracts on private blockchains

There is a general gas cost rule that states that sending message to any non-existing account costs more than sending message to an existing account. That also applies to the accounts of the ...
Paweł Bylica's user avatar
10 votes
Accepted

Truffle Migrations Account Locked Error with --network command

Possible it's not unlocked long enough? web3.personal.unlockAccount(web3.personal.listAccounts[0],"password",15000); // 1st account, pw & time in seconds ...
Rob Hitchens's user avatar
  • 55.3k
10 votes
Accepted

What is the bootnode command in the go-ethereum documentation?

I think it had previously been a part of the "Geth and Tools" release package, but it's gone missing... An issue was raised a couple of days ago: #3703 With regards to what it does, further up the ...
Richard Horrocks's user avatar
10 votes

What is a chainID in Ethereum, how is it different than NetworkID, and how is it used?

Despite the fact that this question has an accepted answer, the original question does not seem to be answered, so I will add my two cents. How is it different than networkID? Network identifier (...
Mikhail Vladimirov's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible