cockroachdb / cockroach

CockroachDB — the cloud native, distributed SQL database designed for high availability, effortless scale, and control over data placement.
https://www.cockroachlabs.com
Other
30.15k stars 3.81k forks source link

backupccl: v24.2.4: nil pointer on error cleanup #134618

Open cockroach-sentry opened 1 week ago

cockroach-sentry commented 1 week ago

This issue was auto filed by Sentry. It represents a crash or reported error on a live cluster with telemetry enabled.

Sentry Link: https://cockroach-labs.sentry.io/issues/6051255736/?referrer=webhooks_plugin

Panic Message:

panic.go:770: runtime error: invalid memory address or nil pointer dereference
(1) attached stack trace
  -- stack trace:
  | runtime.gopanic
  |     GOROOT/src/runtime/panic.go:770
  | runtime.panicmem
  |     GOROOT/src/runtime/panic.go:261
  | runtime.sigpanic
  |     GOROOT/src/runtime/signal_unix.go:881
  | github.com/cockroachdb/cockroach/pkg/ccl/backupccl.doRestorePlan.func1
  |     github.com/cockroachdb/cockroach/pkg/ccl/backupccl/restore_planning.go:1749
  | github.com/cockroachdb/cockroach/pkg/ccl/backupccl.doRestorePlan
  |     github.com/cockroachdb/cockroach/pkg/ccl/backupccl/restore_planning.go:1757
  | github.com/cockroachdb/cockroach/pkg/ccl/backupccl.restorePlanHook.func3
  |     github.com/cockroachdb/cockroach/pkg/ccl/backupccl/restore_planning.go:1430
  | github.com/cockroachdb/cockroach/pkg/sql.(*hookFnNode).startExec.func1
  |     github.com/cockroachdb/cockroach/pkg/sql/planhook.go:199
  | github.com/cockroachdb/cockroach/pkg/util/stop.(*Stopper).RunAsyncTaskEx.func2
  |     github.com/cockroachdb/cockroach/pkg/util/stop/stopper.go:485
  | runtime.goexit
  |     src/runtime/asm_arm64.s:1222
Wraps: (2) runtime error: invalid memory address or nil pointer dereference
Error types: (1) *withstack.withStack (2) runtime.errorString
-- report composition:
runtime.errorString
panic.go:770: *withstack.withStack (top exception)
Stacktrace (expand for inline code snippets): [src/runtime/asm_arm64.s#L1221-L1223](src/runtime/asm_arm64.s#L1221-L1223) [https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/util/stop/stopper.go#L484-L486](https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/util/stop/stopper.go#L484-L486) [https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/sql/planhook.go#L198-L200](https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/sql/planhook.go#L198-L200) [https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/ccl/backupccl/restore_planning.go#L1429-L1431](https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/ccl/backupccl/restore_planning.go#L1429-L1431) [https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/ccl/backupccl/restore_planning.go#L1756-L1758](https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/ccl/backupccl/restore_planning.go#L1756-L1758) [https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/ccl/backupccl/restore_planning.go#L1748-L1750](https://github.com/cockroachdb/cockroach/blob/8140b8e294fb16a293d0aae662bcf5c1d488c852/pkg/ccl/backupccl/restore_planning.go#L1748-L1750) [GOROOT/src/runtime/signal_unix.go#L880-L882](GOROOT/src/runtime/signal_unix.go#L880-L882) [GOROOT/src/runtime/panic.go#L260-L262](GOROOT/src/runtime/panic.go#L260-L262) [GOROOT/src/runtime/panic.go#L769-L771](GOROOT/src/runtime/panic.go#L769-L771)
src/runtime/asm_arm64.s in runtime.goexit at line 1222
pkg/util/stop/stopper.go in pkg/util/stop.(*Stopper).RunAsyncTaskEx.func2 at line 485
pkg/sql/planhook.go in pkg/sql.(*hookFnNode).startExec.func1 at line 199
pkg/ccl/backupccl/restore_planning.go in pkg/ccl/backupccl.restorePlanHook.func3 at line 1430
pkg/ccl/backupccl/restore_planning.go in pkg/ccl/backupccl.doRestorePlan at line 1757
pkg/ccl/backupccl/restore_planning.go in pkg/ccl/backupccl.doRestorePlan.func1 at line 1749
GOROOT/src/runtime/signal_unix.go in runtime.sigpanic at line 881
GOROOT/src/runtime/panic.go in runtime.panicmem at line 261
GOROOT/src/runtime/panic.go in runtime.gopanic at line 770

Tags

Tag Value
Command start-single-node
Environment v24.2.4
Go Version go1.22.5 X:nocoverageredesign
Platform linux arm64
Distribution CCL
Cockroach Release v24.2.4
Cockroach SHA 8140b8e294fb16a293d0aae662bcf5c1d488c852
# of CPUs 4
# of Goroutines 408

Jira issue: CRDB-44168

blathers-crl[bot] commented 4 days ago

cc @cockroachdb/disaster-recovery

jeffswenson commented 4 days ago

https://go.dev/play/p/yfUVfou0XTB