You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
INFO [09-02|22:58:38.845] Maximum peer count ETH=50 LES=0 total=50
INFO [09-02|22:58:38.845] Smartcard socket not found, disabling err="stat /run/pcscd/pcscd.comm: no such file or directory"
INFO [09-02|22:58:38.846] Set global gas cap cap=50,000,000
INFO [09-02|22:58:38.846] Allocated trie memory caches clean=154.00MiB dirty=256.00MiB
INFO [09-02|22:58:38.846] Allocated cache and file handles database=/data/sde/geth_priv/data/geth/chaindata cache=512.00MiB handles=50001
INFO [09-02|22:58:38.870] Opened ancient database database=/data/sde/geth_priv/data/geth/chaindata/ancient readonly=false
INFO [09-02|22:58:38.870] Initialised chain configuration config="{ChainID: 15 Homestead: 0 DAO: DAOSupport: false EIP150: 0 EIP155: 0 EIP158: 0 Byzantium: 0 Constantinople: 0 Petersburg: 0 Istanbul: , Muir Glacier: , Berlin: , London: , Engine: clique}"
INFO [09-02|22:58:38.871] Initialising Ethereum protocol network=12345 dbversion=8
INFO [09-02|22:58:38.871] Loaded most recent local header number=0 hash=895515..ed20ca td=65536 age=52y5mo2d
INFO [09-02|22:58:38.871] Loaded most recent local full block number=0 hash=895515..ed20ca td=65536 age=52y5mo2d
INFO [09-02|22:58:38.871] Loaded most recent local fast block number=0 hash=895515..ed20ca td=65536 age=52y5mo2d
WARN [09-02|22:58:38.872] Loaded snapshot journal diskroot=cce9b3..480599 diffs=missing
INFO [09-02|22:58:38.872] Loaded local transaction journal transactions=0 dropped=0
INFO [09-02|22:58:38.872] Regenerated local transaction journal transactions=0 accounts=0
INFO [09-02|22:58:38.873] Gasprice oracle is ignoring threshold set threshold=2
panic: runtime error: makeslice: len out of range
Hmm looks like you need to specify some extradata in the genesis block, otherwise the snapshot() function will panic , because make([]byte, len(header.extradata) - 32 - 65 / 20) is make([]byte, -3)
So just adding some extraData to the genesis should fix the issue. But we should probably add some check to prevent this from panicing
System information
[root@VM-16-3-centos ~]# geth version
Geth
Version: 1.10.6-stable
Architecture: amd64
Go Version: go1.16.7
Operating System: linux
GOPATH=/root/go-work
GOROOT=/root/go/go
Geth version:
geth version
OS & Version: Windows/Linux/OSX
Commit hash : (if
develop
)Expected behaviour
Geth console run
Actual behaviour
Geth Crash
Steps to reproduce the behaviour
geth --nodiscover --datadir ./data --identity "gethPriv" --networkid 12345 --port 30305 console
LOG
INFO [09-02|22:58:38.845] Maximum peer count ETH=50 LES=0 total=50
INFO [09-02|22:58:38.845] Smartcard socket not found, disabling err="stat /run/pcscd/pcscd.comm: no such file or directory"
INFO [09-02|22:58:38.846] Set global gas cap cap=50,000,000
INFO [09-02|22:58:38.846] Allocated trie memory caches clean=154.00MiB dirty=256.00MiB
INFO [09-02|22:58:38.846] Allocated cache and file handles database=/data/sde/geth_priv/data/geth/chaindata cache=512.00MiB handles=50001
INFO [09-02|22:58:38.870] Opened ancient database database=/data/sde/geth_priv/data/geth/chaindata/ancient readonly=false
INFO [09-02|22:58:38.870] Initialised chain configuration config="{ChainID: 15 Homestead: 0 DAO: DAOSupport: false EIP150: 0 EIP155: 0 EIP158: 0 Byzantium: 0 Constantinople: 0 Petersburg: 0 Istanbul: , Muir Glacier: , Berlin: , London: , Engine: clique}"
INFO [09-02|22:58:38.871] Initialising Ethereum protocol network=12345 dbversion=8
INFO [09-02|22:58:38.871] Loaded most recent local header number=0 hash=895515..ed20ca td=65536 age=52y5mo2d
INFO [09-02|22:58:38.871] Loaded most recent local full block number=0 hash=895515..ed20ca td=65536 age=52y5mo2d
INFO [09-02|22:58:38.871] Loaded most recent local fast block number=0 hash=895515..ed20ca td=65536 age=52y5mo2d
WARN [09-02|22:58:38.872] Loaded snapshot journal diskroot=cce9b3..480599 diffs=missing
INFO [09-02|22:58:38.872] Loaded local transaction journal transactions=0 dropped=0
INFO [09-02|22:58:38.872] Regenerated local transaction journal transactions=0 accounts=0
INFO [09-02|22:58:38.873] Gasprice oracle is ignoring threshold set threshold=2
panic: runtime error: makeslice: len out of range
goroutine 47 [running]:
github.com/ethereum/go-ethereum/consensus/clique.(*Clique).snapshot(0xc000526700, 0x158e4d8, 0xc0001c4000, 0x0, 0x9a5e47a1c155589, 0x88b2b1e66c797971, 0xb2db3fb834c69c2, 0xca20edb157ac52d8, 0x0, 0x0, ...)
github.com/ethereum/go-ethereum/consensus/clique/clique.go:399 +0x505
github.com/ethereum/go-ethereum/consensus/clique.(*Clique).Prepare(0xc000526700, 0x158e4d8, 0xc0001c4000, 0xc000158000, 0xca20edb157ac52d8, 0x0)
github.com/ethereum/go-ethereum/consensus/clique/clique.go:513 +0xef
github.com/ethereum/go-ethereum/miner.(*worker).commitNewWork(0xc000093680, 0xc0002b0350, 0x0, 0x6130e69e)
github.com/ethereum/go-ethereum/miner/worker.go:922 +0x3d6
github.com/ethereum/go-ethereum/miner.(*worker).mainLoop(0xc000093680)
github.com/ethereum/go-ethereum/miner/worker.go:456 +0x7ce
created by github.com/ethereum/go-ethereum/miner.newWorker
github.com/ethereum/go-ethereum/miner/worker.go:228 +0x532
When submitting logs: please submit them as text and not screenshots.
And my config of genesis.json is
{
"config": {
"chainId": 12345,
"homesteadBlock": 0,
"eip150Block": 0,
"eip155Block": 0,
"eip158Block": 0,
"byzantiumBlock": 0,
"constantinopleBlock": 0,
"petersburgBlock": 0
},
"alloc": {
"32d6a98018C98a0afe9d9AbE89326F564e3dc1e7": { "balance": "300000" },
"8898a7CAD4174e0291e89d2b7A9dFb91E6C8F592": { "balance": "400000" }
},
"coinbase": "0x0000000000000000000000000000000000000000",
"difficulty": "0x10000",
"extraData": "",
"gasLimit": "0x2fefd8",
"nonce": "0x0000000000000042",
"mixhash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000",
"timestamp": "0x00"
}
The text was updated successfully, but these errors were encountered: