InsideDarkWeb.com

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

I am attempting to launch a private geth chain with the following command:

geth --datadir=./test-private-blockchain/ init genesis.json

I am receiving the following error:

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

{
  "config": {
        "chainId": 4777,
        "homesteadBlock": 0,
        "eip155Block": 0,
        "eip158Block": 0
    },
  "alloc"      : {},
  "difficulty" : "0x400",
  "extraData"  : "",
  "gasLimit"   : "0x7A1200",
  "parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
  "timestamp"  : "0x00"
}

Ethereum Asked by Leon Africa on November 15, 2021

2 Answers

2 Answers

I would like to add that, when reinitializing, if you only delete the chainData folder inside the geth folder of your datadir, you will retain any previous accounts, although they lose all their ether. For me that is a convenience because I store the account numbers in a param file for my Dapps. And of course the Dapps folder is inside your datadir too, so if you want to keep that, but still reinitialize the blockchain itself, this has worked for me.

Answered by islandBilly on November 15, 2021

Answer is to update genesis.json to include eip150Block:

{
  "config": {
        "chainId": 4777,
        "homesteadBlock": 0,
        "eip150Block": 0,
        "eip155Block": 0,
        "eip158Block": 0
    },
  "alloc"      : {},
  "difficulty" : "0x400",
  "extraData"  : "",
  "gasLimit"   : "0x7A1200",
  "parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
  "timestamp"  : "0x00"
}

delete the data dir :

rm -rf "your data dir"

Then reinitialize.

geth --datadir=./test-private-blockchain/ init genesis.json

Answered by Leon Africa on November 15, 2021

Add your own answers!

Related Questions

ipfs.add is not working

2  Asked on August 26, 2021 by usamafarooq459

       

Call few contract methods from another contract consistently

1  Asked on August 26, 2021 by dmytro-zarezenko

   

Using Ganache with an existing MetaMask account

3  Asked on August 26, 2021 by kuyler007

     

Numerical Value of Bools in Solidity

1  Asked on August 26, 2021 by dansermino

   

What is a active wallet vs inactive

1  Asked on August 26, 2021 by doug-cutler

   

How return variable from simple smart contract

1  Asked on August 26, 2021 by lorenzoberti

 

Transaction mined but state variables aren’t changing

1  Asked on August 26, 2021 by anibis

 

Ask a Question

Get help from others!

© 2021 InsideDarkWeb.com. All rights reserved.