0

To set-up a private network with a given genesis document, I can start with the init command or start mining. With init and an account already existing, I can see the block created from the console (eth.getBlock('latest')). Mining would, of course, create the block (miner.start(1) and also credit the reward to an etherbase account or the eth.accounts[0]. So,

  1. Does init trigger a mining?
  2. Who receives the reward for the genesis block when created with an init?

References:

Creating the genesis block

How do I set up a private ethereum network?

1 Answer 1

1

1) init does not trigger mining. Init creates the first block in your blockchain. miner.start() does start mining process, if you have set a coinbase account

2) Nobody receives the reward for the genesis block. The reward is given to the account 0x0000000000000000000000000000000000000000 , but this account is invalid

4
  • So the genesis block created from an init was not mined unless it was created out of miner.start(1)? I mean, as far as genesis block creation is concerned how is initialization and mining different? Mar 20, 2018 at 2:56
  • if you start geth without init it is going to attempt to mine Ethereum's Main Net blockchain, not your private blockchain. do a `eth.getBlock(0) and see the hash of the block, it must be the hash of your genesis not the 0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3
    – Nulik
    Mar 20, 2018 at 3:05
  • initialization is required before mining so the node knows what blockchain is it working with. geth skips the init process to make it easier to join Ethereum's Main Net, but for private chains you have to do init when you create the node.
    – Nulik
    Mar 20, 2018 at 3:07
  • So, init is a per-requisite for mining in private networks. Thanks! Mar 20, 2018 at 3:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.