Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fast-synced node crushes #22129

Closed
liquid-8 opened this issue Jan 6, 2021 · 0 comments · Fixed by #22135
Closed

Fast-synced node crushes #22129

liquid-8 opened this issue Jan 6, 2021 · 0 comments · Fixed by #22135
Labels

Comments

@liquid-8
Copy link

liquid-8 commented Jan 6, 2021

System information

Geth version: 1.9.25
OS & Version: Windows 10

Expected behaviour

Fast synced geth starts and works as local node

Actual behaviour

Fast synced geth throws the error at startup

panic: runtime error: invalid memory address or nil pointer dereference

and shuts down then

Steps to reproduce the behaviour

runs w/admin privs as follow

Z:\gth\geth.exe --datadir ".\data" --syncmode fast --cache 1024 --http --http.addr 127.0.0.1 --http.port 8545

Backtrace

panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x0 pc=0xd5717a]

goroutine 1 [running]:
github.com/ethereum/go-ethereum/core/types.(*Block).Root(...)
        github.com/ethereum/go-ethereum/core/types/block.go:336
github.com/ethereum/go-ethereum/core.(*BlockChain).SetHeadBeyondRoot.func1(0x217217b5a68, 0xc000099f60, 0xc008ed8480, 0x217217b5a68, 0xc000099f60)
        github.com/ethereum/go-ethereum/core/blockchain.go:528 +0x31a
github.com/ethereum/go-ethereum/core.(*BlockChain).SetHeadBeyondRoot(0xc0000df900, 0xb0ec07, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
        github.com/ethereum/go-ethereum/core/blockchain.go:606 +0x2a8
github.com/ethereum/go-ethereum/core.(*BlockChain).SetHead(...)
        github.com/ethereum/go-ethereum/core/blockchain.go:484
github.com/ethereum/go-ethereum/core.NewBlockChain(0x1b357a0, 0xc000099f60, 0xc0018102d0, 0x1649020, 0x1b33260, 0xc0003696c0, 0x0, 0x0, 0x0, 0x0, ...)
        github.com/ethereum/go-ethereum/core/blockchain.go:310 +0x1b18
github.com/ethereum/go-ethereum/eth.New(0xc00029b2b0, 0xc000125200, 0x1636ba0, 0x1, 0x1)
        github.com/ethereum/go-ethereum/eth/backend.go:175 +0xae5
github.com/ethereum/go-ethereum/cmd/utils.RegisterEthService(0xc00029b2b0, 0xc000125200, 0x0, 0x1)
        github.com/ethereum/go-ethereum/cmd/utils/flags.go:1701 +0xec
main.makeFullNode(0xc00029c2c0, 0x18ff47f, 0x1, 0xc000005b80)
        github.com/ethereum/go-ethereum/cmd/geth/config.go:165 +0xfe
main.geth(0xc00029c2c0, 0x0, 0x0)
        github.com/ethereum/go-ethereum/cmd/geth/main.go:354 +0x105
gopkg.in/urfave/cli%2ev1.HandleAction(0x1730e40, 0x19db098, 0xc00029c2c0, 0xc00007ae40, 0x0)
        gopkg.in/urfave/[email protected]/app.go:490 +0x89
gopkg.in/urfave/cli%2ev1.(*App).Run(0xc00008e9c0, 0xc0000d8000, 0xc, 0x10, 0x0, 0x0)
        gopkg.in/urfave/[email protected]/app.go:264 +0x5f5
main.main()
        github.com/ethereum/go-ethereum/cmd/geth/main.go:273 +0x5c

Thanks in advance!

holiman pushed a commit that referenced this issue Jan 25, 2021
When a sethead/rewind finds that the targeted block is missing, it resets to genesis instead of crashing. Closes #22129
bulgakovk pushed a commit to bulgakovk/go-ethereum that referenced this issue Jan 26, 2021
When a sethead/rewind finds that the targeted block is missing, it resets to genesis instead of crashing. Closes ethereum#22129
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant