Skip to content

storage: clobbering between uninitialized replica and RHS of a split #7600

@tbg

Description

@tbg

As discussed in #6991, but now also directly observed (on master) in

$ make stressrace PKG=./storage TESTS=TestStoreRangeDownReplicate STRESSFLAGS='-p 16 -maxfails 1 -stderr':

E160701 20:01:54.022089 raft/raft.go:925  [group 2] 3 state.commit 0 is out of range [10, 10]
panic: [group 2] 3 state.commit 0 is out of range [10, 10]

goroutine 320 [running]:
panic(0x5611dc0, 0xc820994420)
    /usr/local/Cellar/go/1.6.2/libexec/src/runtime/panic.go:481 +0x3ff
github.com/cockroachdb/cockroach/storage.(*raftLogger).Panicf(0xc820994330, 0x5bc7f20, 0x2b, 0xc82099c5c0, 0x4, 0x4)
    /Users/tschottdorf/go/src/github.com/cockroachdb/cockroach/storage/raft.go:117 +0x1cb
github.com/coreos/etcd/raft.(*raft).loadState(0xc82095c340, 0x6, 0x1, 0x0, 0x0, 0x0, 0x0)
    /Users/tschottdorf/go/src/github.com/coreos/etcd/raft/raft.go:925 +0x3f6
github.com/coreos/etcd/raft.newRaft(0xc820945b38, 0x30303c820945860)
    /Users/tschottdorf/go/src/github.com/coreos/etcd/raft/raft.go:225 +0xcd9
github.com/coreos/etcd/raft.NewRawNode(0xc820945b38, 0x0, 0x0, 0x0, 0xc8209fa190, 0x0, 0x0)

#7598 should fix this.

Metadata

Metadata

Assignees

Labels

C-bugCode not up to spec/doc, specs & docs deemed correct. Solution expected to change code/behavior.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions