PD exit when removing evict-leader-scheduler after an unsafe operation
- Dominant language
- Go
- Stars
- 1.2k
- Forks
- 783
- Avg merge
- 5d 21h
- Merged PRs (30d)
- 36
Description
### What did you do?
Offline a store, but before the store leader finishes transferring, use API to set the store to tombstone and remove it (**unsafe operation**). We can find the evict leader scheduler is still existed. Then manually remove the scheduler by using scheduler removes `evict-leader-scheduler` in `pd-ctl`.
### What did you expect to see?
The scheduler can be removed.
### What did you see instead?
PD exit with the error in the following:
```
[2021/01/07 04:29:36.177 +00:00] [FATAL] [store.go:533] ["try to clean a store's pause state, but it is not found"] [store-id=44418796] [error="[PD:core:ErrS
toreNotFound]store 44418796 not found"] [stack="github.com/pingcap/log.Fatal\n\t/.../program/go/pkg/mod/github.com/pingcap/log@v0.0.0-20201112100606-8f
1e84a3abc8/global.go:59\ngithub.com/tikv/pd/server/core.(*StoresInfo).ResumeLeaderTransfer\n\t/.../program/go/src/github.com/pingcap/pd/server/core/sto
re.go:533\ngithub.com/tikv/pd/server/core.(*BasicCluster).ResumeLeaderTransfer\n\t/.../program/go/src/github.com/pingcap/pd/server/core/basic_cluster.g
o:145\ngithub.com/tikv/pd/server/cluster.(*RaftCluster).ResumeLeaderTransfer\n\t/.../program/go/src/github.com/pingcap/pd/server/cluster/cluster.go:109
0\ngithub.com/tikv/pd/server/schedulers.(*evictLeaderScheduler).Cleanup\n\t/.../program/go/src/github.com/pingcap/pd/server/schedulers/evict_leader.go:
206\ngithub.com/tikv/pd/server/cluster.(*coordinator).runScheduler\n\t/.../program/go/src/github.com/pingcap/pd/server/cluster/coordinator.go:740"]
```
### What version of PD are you using (`pd-server -V`)?
5.0-rc
Contributor guide
Assessment
This issue has not been assessed yet.