Immutable solution version
fatal error: sync: unlock of unlocked mutex (v8.5.0 stmtctx.go:803)
Complete solution
[chibiegg (reporter)]: Based on what I’ve seen, in my environment, every occurrence of the panic happened during calls originating from setDataForProcessList (infoschema_reader.go:1843). I’ll try running the patch you provided on my local environment.
What was reported: GitHub issue pingcap/tidb#58600 (closed, 25 comments): ## Bug Report Please answer these questions before submitting your issue. Thanks! ### 1. Minimal reproduce step (Required) I'm sorry, but I'm not sure how to reproduce the issue. It occurs sporadically on multiple running TiDB processes. ### 2. What did you expect to see? (Required) ### 3. What did you see instead (Required) fatal error on https://github.com/pingcap/tidb/blob/d13e52ed6e22cc5789bed7c64c861578cd2ed55b/pkg/sessionctx/stmtctx/stmtctx.go#L800-L804 . These errors always occur on the same line. ``` fatal error: sync: unlock of unlocked mutex goroutine 322590843 [running]: sync.fatal(
What works: [chibiegg (reporter)]: Based on what I’ve seen, in my environment, every occurrence of the panic happened during calls originating from setDataForProcessList (infoschema_reader.go:1843). I’ll try running the patch you provided on my local environment. If it works, should we skip the previously committed workaround and only introduce the handling of RefCountOfStmtCtx? Or is it better to keep both changes?
Evidence
In the GitHub issue, the reporter asked: fatal error: sync: unlock of unlocked mutex (v8.5.0 stmtctx.go:803). The working answer that came out of the thread: [chibiegg (reporter)]: Based on what I’ve seen, in my environment, every occurrence of the panic happened during calls originating from setDataForProcessList (infoschema_reader.go:1843). I’ll try running the patch you provided on my local environment. If it works, should we skip the previously committed workaround and only introduce the handling of RefCountOfStmtCtx? Or is it better to keep both changes? Source: https://github.com/pingcap/tidb/issues/58600
By @issueatlas · Version 1 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_msSNXyd4ztU4UYx1YW_ROQ" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">fatal error: sync: unlock of unlocked mutex (v8.5.0 stmtctx.go:803) <span>— Vectle</span></a>