Skip to content
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

kvserver: v21.2.9: not using applied state key in v21.1 #83763

Closed
cockroach-teamcity opened this issue Jul 3, 2022 · 1 comment
Closed

kvserver: v21.2.9: not using applied state key in v21.1 #83763

cockroach-teamcity opened this issue Jul 3, 2022 · 1 comment
Assignees
Labels
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. T-kv KV Team

Comments

@cockroach-teamcity
Copy link
Member

cockroach-teamcity commented Jul 3, 2022

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

Sentry link: https://sentry.io/organizations/cockroach-labs/issues/3398694605/?referrer=webhooks_plugin

Panic message:

replica_proposal.go:898: log.Fatal: not using applied state key in v21.1
(1) attached stack trace
-- stack trace:
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).evaluateProposal
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_proposal.go:898
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).requestToProposal
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_proposal.go:933
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).evalAndPropose
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_raft.go:110
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).executeWriteBatch
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_write.go:156
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).executeBatchWithConcurrencyRetries
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_send.go:377
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).sendWithRangeID
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_send.go:107
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).Send
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_send.go:43
| github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*pendingLeaseRequest).requestLeaseAsync.func2
| /go/src/github.com/cockroachdb/cockroach/pkg/kv/kvserver/replica_range_lease.go:427
| github.com/cockroachdb/cockroach/pkg/util/stop.(*Stopper).RunAsyncTaskEx.func2
| /go/src/github.com/cockroachdb/cockroach/pkg/util/stop/stopper.go:442
| runtime.goexit
| /usr/local/go/src/runtime/asm_amd64.s:1371
Wraps: (2) log.Fatal: not using applied state key in v21.1
Error types: (1) *withstack.withStack (2) *errutil.leafError
-- report composition:
*errutil.leafError: log.Fatal: not using applied state key in v21.1
replica_proposal.go:898: *withstack.withStack (top exception)

Stacktrace (expand for inline code snippets):

if migrationVersion.Less(activeVersion) {
log.Fatal(ctx, "not using applied state key in v21.1")
}
in pkg/kv/kvserver.(*Replica).evaluateProposal
) (*ProposalData, *roachpb.Error) {
res, needConsensus, pErr := r.evaluateProposal(ctx, idKey, ba, lul, latchSpans, lockSpans)
in pkg/kv/kvserver.(*Replica).requestToProposal
idKey := makeIDKey()
proposal, pErr := r.requestToProposal(ctx, idKey, ba, st, lul, g.LatchSpans(), g.LockSpans())
log.Event(proposal.ctx, "evaluated request")
in pkg/kv/kvserver.(*Replica).evalAndPropose
// evalAndPropose.
ch, abandon, _, pErr := r.evalAndPropose(ctx, ba, g, st, localUncertaintyLimit, tok.Move(ctx))
if pErr != nil {
in pkg/kv/kvserver.(*Replica).executeWriteBatch
br, g, pErr = fn(r, ctx, ba, g)
if pErr == nil {
in pkg/kv/kvserver.(*Replica).executeBatchWithConcurrencyRetries
fn := (*Replica).executeWriteBatch
br, pErr = r.executeBatchWithConcurrencyRetries(ctx, ba, fn)
} else if ba.IsAdmin() {
in pkg/kv/kvserver.(*Replica).sendWithRangeID
) (*roachpb.BatchResponse, *roachpb.Error) {
return r.sendWithRangeID(ctx, r.RangeID, &ba)
}
in pkg/kv/kvserver.(*Replica).Send
ba.Add(leaseReq)
_, pErr = p.repl.Send(ctx, ba)
}
in pkg/kv/kvserver.(*pendingLeaseRequest).requestLeaseAsync.func2
f(ctx)
}()
in pkg/util/stop.(*Stopper).RunAsyncTaskEx.func2
/usr/local/go/src/runtime/asm_amd64.s#L1370-L1372 in runtime.goexit

pkg/kv/kvserver/replica_proposal.go in pkg/kv/kvserver.(*Replica).evaluateProposal at line 898
pkg/kv/kvserver/replica_proposal.go in pkg/kv/kvserver.(*Replica).requestToProposal at line 933
pkg/kv/kvserver/replica_raft.go in pkg/kv/kvserver.(*Replica).evalAndPropose at line 110
pkg/kv/kvserver/replica_write.go in pkg/kv/kvserver.(*Replica).executeWriteBatch at line 156
pkg/kv/kvserver/replica_send.go in pkg/kv/kvserver.(*Replica).executeBatchWithConcurrencyRetries at line 377
pkg/kv/kvserver/replica_send.go in pkg/kv/kvserver.(*Replica).sendWithRangeID at line 107
pkg/kv/kvserver/replica_send.go in pkg/kv/kvserver.(*Replica).Send at line 43
pkg/kv/kvserver/replica_range_lease.go in pkg/kv/kvserver.(*pendingLeaseRequest).requestLeaseAsync.func2 at line 427
pkg/util/stop/stopper.go in pkg/util/stop.(*Stopper).RunAsyncTaskEx.func2 at line 442
/usr/local/go/src/runtime/asm_amd64.s in runtime.goexit at line 1371
Tag Value
Cockroach Release v21.2.9
Cockroach SHA: 11787ed
Platform linux amd64
Distribution CCL
Environment v21.2.9
Command server
Go Version ``
# of CPUs
# of Goroutines

Jira issue: CRDB-17245

@cockroach-teamcity 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 Jul 3, 2022
@yuzefovich yuzefovich changed the title sentry: replica_proposal.go:898: log.Fatal: not using applied state key in v21.1 (1) attached stack trace -- stack trace: | github.com/cockroachdb/cockroach/pkg/kv/kvserver.(*Replica).evaluateProposal |... kvserver: v21.2.9: not using applied state key in v21.1 Jul 20, 2022
@blathers-crl blathers-crl bot added the T-kv KV Team label Jul 20, 2022
@nvanbenschoten nvanbenschoten self-assigned this Jul 26, 2022
@nvanbenschoten
Copy link
Member

We see that this fatal was hit all on the same cluster and that this is the same failure mode we saw in #62267. That issue was fixed by #62838.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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. T-kv KV Team
Projects
None yet
Development

No branches or pull requests

2 participants