-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
sql: v23.1.1: nil pointer in getContentionEventInfo #104406
Comments
cockroach-teamcity
added
C-bug
Code not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.
O-sentry
Originated from an in-the-wild panic report.
labels
Jun 6, 2023
yuzefovich
changed the title
sentry: panic.go:884: runtime error: invalid memory address or nil pointer dereference
(1) attached stack trace
-- stack trace:
| runtime.gopanic
| GOROOT/src/runtime/panic.go:884
| runtime.panicmem
...
sql: v23.1.1: nil pointer in getContentionEventInfo
Jun 8, 2023
We're incorrectly checking |
craig bot
pushed a commit
that referenced
this issue
Jul 5, 2023
105832: upgrades: try to repair catalog corruptions during upgrade r=postamar a=postamar This change enhances the recently-added upgrade precondition check which checks for catalog corruptions by trying to repair these automatically when possible. Fixes: #104425 Fixes: #85265 Release note (general change): upgrading the cluster version to a new release will not only check for descriptor- and other catalog corruptions but will attempt to repair some of them on a best-effort basis. This should seamlessly get rid of all longstanding descriptor back-reference corruptions, which typically don't manifest themselves until a schema change or an upgrade are performed. 106185: sql: fix nil pointer dereference in crdb_internal.transaction_contention_events r=zachlite a=zachlite `schemaDesc` was not checked for a nil pointer before dereferencing it. `schemaDesc` can be nil under the following conditions: 1. A schema descriptor can be deleted, in which case all of its tables would be deleted too. 2. The transaction used to retrieve the descriptor fails. Given the structure of `getContentionEventInfo`, this nil pointer dereference is only possible under scenario 2: If a schema and its tables are deleted, a nil table descriptor would force an early return, and this code path would not execute. Fixes: #104406 Epic: none Release note: None Co-authored-by: Marius Posta <[email protected]> Co-authored-by: zachlite <[email protected]>
blathers-crl bot
pushed a commit
that referenced
this issue
Jul 5, 2023
…ion_events schemaDesc was not checked for a nil pointer before dereferencing it. schemaDesc can be nil under the following conditions: 1. A schema descriptor can be deleted, in which case all of its tables would be deleted too. 2. The transaction used to retrieve the descriptor fails. Given the structure of `getContentionEventInfo`, this nil pointer dereference is only possible under scenario 2. If a schema and its tables are deleted, a nil table descriptor would force an early return, and this code path would not execute. Fixes: #104406 Epic: none Release note: None
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This issue was autofiled by Sentry. It represents a crash or reported error on a live cluster with telemetry enabled.
Sentry link: https://cockroach-labs.sentry.io/issues/4231557744/?referrer=webhooks_plugin
Panic message:
Stacktrace (expand for inline code snippets):
GOROOT/src/runtime/panic.go#L883-L885 in runtime.gopanic
GOROOT/src/runtime/panic.go#L259-L261 in runtime.panicmem
GOROOT/src/runtime/signal_unix.go#L834-L836 in runtime.sigpanic
cockroach/pkg/sql/crdb_internal.go
Lines 7894 to 7896 in 00f65ea
cockroach/pkg/sql/crdb_internal.go
Lines 7040 to 7042 in 00f65ea
cockroach/pkg/sql/virtual_table.go
Lines 126 to 128 in 00f65ea
cockroach/pkg/util/stop/stopper.go
Lines 469 to 471 in 00f65ea
GOROOT/src/runtime/asm_amd64.s#L1593-L1595 in runtime.goexit
v23.1.1
Jira issue: CRDB-28514
The text was updated successfully, but these errors were encountered: