tikv / tikv/pd

PD transfers leader to a pending peer

Open
#1,649 1 comment 0 reactions 0 assignees View on GitHub
component/schedule type/enhancement
Dominant language
Go
Stars
1.2k
Forks
783
Avg merge
5d 21h
Merged PRs (30d)
36

Description

Please answer these questions before submitting your issue. Thanks!

1. What did you do?
```
./pd-ctl -u 10.233.100.247:2379 region 56317
{
"id": 56317,
"start_key": "7480000000000000FFF55F698000000000FF0000010130303030FF30303030FF303030FF3030303030FF3030FF303030303030FF30FF30303030303030FFFF3030303030303032FFFF34303231313336FF38FF000000000000FF0000F70400000000FF0E5155A801376162FF3366363833FF6639FF643766333135FF38FF63363065663435FFFF3139313933396236FFFF00000000000000FF00F7040000000000FF0000000400000000FF0000000000000000FB",
"end_key": "7480000000000000FFF55F698000000000FF0000010130303030FF30303030FF303030FF3030303030FF3030FF303030303030FF30FF30303030303030FFFF3030303030303032FFFF35303038343932FF34FF000000000000FF0000F70400000000FF0EE7FE3F01383431FF6330386162FF6530FF313031376536FF38FF39326137636363FFFF3033656138373462FFFF00000000000000FF00F7040000000000FF0000000400000000FF0000000000000000FB",
"epoch": {
"conf_ver": 37,
"version": 237
},
"peers": [
{
"id": 56318,
"store_id": 1
},
{
"id": 56319,
"store_id": 6
},
{
"id": 56320,
"store_id": 9
},
{
"id": 57144,
"store_id": 5
}
],
"leader": {
"id": 56318,
"store_id": 1
},
"pending_peers": [
{
"id": 56319,
"store_id": 6
}
],
"written_bytes": 19350993,
"approximate_size": 123,
"approximate_keys": 624077
}
```

2. What did you expect to see?

PD will do scheduling quickly.

3. What did you see instead?

PD tries to transfer leader for region 56317 from store 1 to store 6 which contains a pending peer, and it makes PD to repeatedly do this operation, which blocks the scheduling procedure.
[hot-region.log](https://github.com/pingcap/pd/files/3425649/hot-region.log)

4. What version of PD are you using (`pd-server -V`)?
```
Release Version: v3.0.0-2-gee98bf9
Git Commit Hash: ee98bf9063e9aef9e23e02fdf0a3b20b96e32d20
Git Branch: pingcap/release-3.0
UTC Build Time: 2019-07-11 03:50:52
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.