Skip to content

The region statistic does not match the hot read statistics #3245

Closed
@rleungx

Description

Bug Report

What did you do?

Run sysbench read_only workload.

What did you expect to see?

The hot region is balanced and the number of the hot regions is almost the same.

What did you see instead?

From the hot read in pd-ctl:

"104": {
    "total_flow_bytes": 12236445.15,
    "total_flow_keys": 50156.25,
    "regions_count": 1,
    "statistics": [
        {
            "store_id": 104,
            "region_id": 186247997,
            "hot_degree": 566,
            "anti_count": 2,
            "kind": 1,
            "flow_bytes": 12092750.38095238,
            "flow_keys": 49560.45238095238,
            "RollingByteRate": null,
            "RollingKeyRate": null,
            "last_update_time": "2020-12-02T02:50:43.921713736Z",
            "version": 129
        }
    ]
}

We find there is only one hot region in store 104 and the region id is 186247997.

Use pd-ctl region 186247997:

{
  "id": 186247997,
  "start_key": "7480000000000000FFA55F728000000000FF0013C60000000000FA",
  "end_key": "7480000000000000FFA55F728000000000FF00140C0000000000FA",
  "epoch": {
    "conf_ver": 77,
    "version": 129
  },
  "peers": [
    {
      "id": 186247998,
      "store_id": 1
    },
    {
      "id": 186247999,
      "store_id": 104
    },
    {
      "id": 186248000,
      "store_id": 66
    }
  ],
  "leader": {
    "id": 186247999,
    "store_id": 104
  },
  "written_bytes": 0,
  "read_bytes": 0,
  "written_keys": 0,
  "read_keys": 0,
  "approximate_size": 1,
  "approximate_keys": 0
}

What version of PD are you using (pd-server -V)?

master

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions