duanou1904 2018-03-05 03:00
浏览 82
已采纳

格思如何保持区块链地位?

Fedora 27, CentOS 1708, Go-ethereum 1.8.1

I am trying to make private block chain and coin using that for study.

Genesis.json:

{
  "config": {
        "chainId": 42,
        "homesteadBlock": 0,
        "eip155Block": 0,
        "eip158Block": 0
    },
  "alloc": {},
  "coinbase"   : "0x0000000000000000000000000000000000000000",
  "difficulty" : "0x1000000",
  "extraData"  : "",
  "gasLimit"   : "0x2fefd8",
  "nonce"      : "0x0000000012345678",
  "mixhash"    : "0x0000000000000000000000000000000000000000000000000000000000000000",
  "parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
  "timestamp"  : "0x00"
}

And I run geth in console with:

geth init genesis.json --datadir datadir
geth console --rpc --rpcport "8080" --rpccorsdomain "*" --datadir "datadir" --port "30303" --nodiscover --rpcapi "db,eth,net,web3" --networkid 7296

Then I made new account and started mining. It works. But when I restart geth, block chain state seems not saved.

INFO [03-05|11:39:03] Successfully sealed new block            number=21 hash=ef088f…8b62cb
INFO [03-05|11:39:03]
  • 写回答

1条回答 默认 最新

  • douxing8855 2018-03-05 12:47
    关注

    maybe a bug in the current version... start geth with option --gcmode "archive"

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?