2

我目前正在运行最新的 Geth 1.8.1 Iceburg 版本。我按照教程设置了一个私有以太坊网络,包括挖矿在内的一切工作正常,但是每次我重新启动 Geth 时,链都会重置回第 0 号区块,所有挖矿交易都丢失了,也没有 ETH 余额,但交易记录在日志。

使用的命令:

geth --datadir "$ethereum_home/EthMasterChain" console 2>console.log

geth --datadir "$ethereum_home/EthMasterChain" init "$ethereum_home/genesis.json"

使用的json文件:

{
    "config": {
    "chainId": 1234,
        "homesteadBlock": 0,
        "eip155Block": 0,
        "eip158Block": 0
    },
    "nonce": "0x0000000000000045",
    "timestamp": "0x0",
    "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
    "gasLimit": "0x8900000",
    "difficulty": "0x400",
    "mixhash": "0x0000000000000000000000000000000000000000000000000000000000000000",
    "coinbase": "0xbe8d5fce9f60ab06b527dd177eed96eb95ee4138",
    "alloc": {
        "0xbe8d5fce9f60ab06b527dd177eed96eb95ee4138" : {"balance" : "10000000000000000000"}
    }

}
4

0 回答 0