-
Notifications
You must be signed in to change notification settings - Fork 6k
Closed
Labels
affects-8.5This bug affects the 8.5.x(LTS) versions.This bug affects the 8.5.x(LTS) versions.impact/panicmay-affects-8.1severity/majorsig/plannerSIG: PlannerSIG: Plannertype/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.
Description
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
million tables and dml
[2025/01/10 14:33:39.198 +00:00] [ERROR] [misc.go:116] ["panic in the recoverable goroutine"] [label=stats] [funcInfo=CallWithSCtx] [r="runtime error: invalid memory address or nil pointer dereference"] [stack="github.com/pingcap/tidb/pkg/util.Recover\n\t/workspace/source/tidb/pkg/util/misc.go:120\nruntime.gopanic\n\t/usr/local/go/src/runtime/panic.go:785\nruntime.panicmem\n\t/usr/local/go/src/runtime/panic.go:262\nruntime.sigpanic\n\t/usr/local/go/src/runtime/signal_unix.go:917\ngithub.com/pingcap/tidb/pkg/statistics.(*Index).MemoryUsage\n\t/workspace/source/tidb/pkg/statistics/index.go:175\ngithub.com/pingcap/tidb/pkg/statistics.(*Table).MemoryUsage\n\t/workspace/source/tidb/pkg/statistics/table.go:578\ngithub.com/pingcap/tidb/pkg/statistics/handle/cache/internal/lfu.(*LFU).Put\n\t/workspace/source/tidb/pkg/statistics/handle/cache/internal/lfu/lfu_cache.go:101\ngithub.com/pingcap/tidb/pkg/statistics/handle/cache.(*StatsCache).Update\n\t/workspace/source/tidb/pkg/statistics/handle/cache/statscacheinner.go:170\ngithub.com/pingcap/tidb/pkg/statistics/handle/cache.(*StatsCacheImpl).UpdateStatsCache\n\t/workspace/source/tidb/pkg/statistics/handle/cache/statscache.go:269\ngithub.com/pingcap/tidb/pkg/statistics/handle/storage.loadNeededIndexHistograms\n\t/workspace/source/tidb/pkg/statistics/handle/storage/read.go:787\ngithub.com/pingcap/tidb/pkg/statistics/handle/storage.LoadNeededHistograms\n\t/workspace/source/tidb/pkg/statistics/handle/storage/read.go:595\ngithub.com/pingcap/tidb/pkg/statistics/handle/storage.(*statsReadWriter).LoadNeededHistograms.func1\n\t/workspace/source/tidb/pkg/statistics/handle/storage/stats_read_writer.go:264\ngithub.com/pingcap/tidb/pkg/statistics/handle/util.WrapTxn\n\t/workspace/source/tidb/pkg/statistics/handle/util/util.go:203\ngithub.com/pingcap/tidb/pkg/statistics/handle/util.CallWithSCtx\n\t/workspace/source/tidb/pkg/statistics/handle/util/util.go:101\ngithub.com/pingcap/tidb/pkg/statistics/handle/storage.(*statsReadWriter).LoadNeededHistograms\n\t/workspace/source/tidb/pkg/statistics/handle/storage/stats_read_writer.go:262\ngithub.com/pingcap/tidb/pkg/domain.(*Domain).asyncLoadHistogram\n\t/workspace/source/tidb/pkg/domain/domain.go:2621\ngithub.com/pingcap/tidb/pkg/util.(*WaitGroupEnhancedWrapper).Run.func1\n\t/workspace/source/tidb/pkg/util/wait_group_wrapper.go:103"]
2. What did you expect to see? (Required)
3. What did you see instead (Required)
4. What is your TiDB version? (Required)
Release Version: v9.0.0-alpha-86-g1d0c33a
Edition: Community
Git Commit Hash: 1d0c33a
Git Branch: HEAD
UTC Build Time: 2025-01-10 04:57:00
GoVersion: go1.23.4
Race Enabled: false
Check Table Before Drop: false
Store: unistore
Metadata
Metadata
Assignees
Labels
affects-8.5This bug affects the 8.5.x(LTS) versions.This bug affects the 8.5.x(LTS) versions.impact/panicmay-affects-8.1severity/majorsig/plannerSIG: PlannerSIG: Plannertype/bugThe issue is confirmed as a bug.The issue is confirmed as a bug.