go-ethereum icon indicating copy to clipboard operation
go-ethereum copied to clipboard

Filtermap crash in dev mode

Open lightclient opened this issue 7 months ago • 2 comments

commit hash: 0db99f4e409b05c109cffac26c15dd641757a3ab

INFO [05-09|14:54:34.902] Stopping work on payload                 id=0x03d3309580564ba4 reason=delivery
INFO [05-09|14:54:34.904] Imported new potential chain segment     number=274 hash=7cb14e..23db6d blocks=1 txs=0 mgas=0.000 elapsed=3.232ms     mgasps=0.000   snap
diffs=82.77KiB triediffs=459.22KiB triedirty=66.95KiB
INFO [05-09|14:54:34.905] Chain head was updated                   number=274 hash=7cb14e..23db6d root=b07826..a0535e elapsed="124.125µs"
panic: fatal: 000037.log:
        orig err: open /Users/matt/dev/go-ethereum/data/geth/chaindata/000037.log: no such file or directory
        list err: open /Users/matt/dev/go-ethereum/data/geth/chaindata: no such file or directory

goroutine 104 [running]:
github.com/ethereum/go-ethereum/ethdb/pebble.panicLogger.Fatalf(...)
        /Users/matt/dev/go-ethereum/ethdb/pebble/pebble.go:142
github.com/cockroachdb/pebble/internal/base.MustExist({0x104927c40, 0x140001ffb08}, {0x140003354c0, 0x3a}, {0x12cc48518, 0x1057fa740}, {0x104909b40, 0x140017ef170}
)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/internal/base/filenames.go:182 +0x1d0
github.com/cockroachdb/pebble.(*DB).rotateWAL(0x1400062b208)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/db.go:2620 +0x3d8
github.com/cockroachdb/pebble.(*DB).makeRoomForWrite(0x1400062b208, 0x140000e0300)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/db.go:2474 +0x32c
github.com/cockroachdb/pebble.(*DB).commitWrite(0x1400062b208, 0x140000e0300, 0x0, 0x0)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/db.go:940 +0x1a0
github.com/cockroachdb/pebble.(*commitPipeline).prepare(0x1400059a000, 0x140000e0300, 0xc0?, 0x88?)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/commit.go:466 +0x1ac
github.com/cockroachdb/pebble.(*commitPipeline).Commit(0x1400059a000, 0x140000e0300, 0x0, 0x0)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/commit.go:315 +0xa0
github.com/cockroachdb/pebble.(*DB).applyInternal(0x1400062b208, 0x140000e0300, 0x100000000?, 0x0)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/db.go:854 +0x1c4
github.com/cockroachdb/pebble.(*DB).Apply(...)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/db.go:780
github.com/cockroachdb/pebble.(*Batch).Commit(...)
        /Users/matt/dev/go-workspace/pkg/mod/github.com/cockroachdb/[email protected]/batch.go:1329
github.com/ethereum/go-ethereum/ethdb/pebble.(*batch).Write(0xd63f6ceda94eb17c?)
        /Users/matt/dev/go-ethereum/ethdb/pebble/pebble.go:579 +0x104
github.com/ethereum/go-ethereum/core/filtermaps.(*mapRenderer).writeFinishedMaps(0x14000fdf020, 0x14000647ee8)
        /Users/matt/dev/go-ethereum/core/filtermaps/map_renderer.go:509 +0x778
github.com/ethereum/go-ethereum/core/filtermaps.(*mapRenderer).run(0x14000fdf020, 0x14000647ee8, 0x14000647ed8)
        /Users/matt/dev/go-ethereum/core/filtermaps/map_renderer.go:294 +0x1bc
github.com/ethereum/go-ethereum/core/filtermaps.(*FilterMaps).tryIndexHead(0x14000165408)
        /Users/matt/dev/go-ethereum/core/filtermaps/indexer.go:248 +0xc0
github.com/ethereum/go-ethereum/core/filtermaps.(*FilterMaps).indexerLoop(0x14000165408)
        /Users/matt/dev/go-ethereum/core/filtermaps/indexer.go:61 +0x154
created by github.com/ethereum/go-ethereum/core/filtermaps.(*FilterMaps).Start in goroutine 1
        /Users/matt/dev/go-ethereum/core/filtermaps/filtermaps.go:291 +0x170
exit status 2

lightclient avatar May 09 '25 22:05 lightclient

Hi,

I'd like to work on this over weekend, but I'm having trouble reproducing the issue locally. My geth dev instance runs smoothly without encountering the error.

Would you be able to provide if any possible:

  1. Any specific steps or conditions that trigger the crash
  2. Your devnet data directory (or a minimal version that reproduces the issue)
  3. Any specific geth configuration flags you were using

This would help me reproduce the problem reliably so I can develop and test a proper fix.

Thanks !

Image

the-shadow-coder avatar May 10 '25 21:05 the-shadow-coder

Looks like it is a bug in Pebble. I'm guessing probably some edge-case that was randomly triggered by just letting dev mode run and generate blocks.

jwasinger avatar May 11 '25 04:05 jwasinger

would like to work on this

rose2221 avatar Jun 16 '25 23:06 rose2221