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

pd-control: add description for scheduler config evict-leader-scheduler (#17968) #18077

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 26 additions & 6 deletions pd-control.md
Original file line number Diff line number Diff line change
Expand Up @@ -686,12 +686,14 @@ Use this command to view and control the scheduling policy.
Usage:

```bash
>> scheduler show // Display all schedulers
>> scheduler add grant-leader-scheduler 1 // Schedule all the leaders of the Regions on store 1 to store 1
>> scheduler add evict-leader-scheduler 1 // Move all the Region leaders on store 1 out
>> scheduler config evict-leader-scheduler // Display the stores in which the scheduler is located since v4.0.0
>> scheduler add shuffle-leader-scheduler // Randomly exchange the leader on different stores
>> scheduler add shuffle-region-scheduler // Randomly scheduling the Regions on different stores
>> scheduler show // Display all schedulers
>> scheduler add grant-leader-scheduler 1 // Schedule all the leaders of the Regions on store 1 to store 1
>> scheduler add evict-leader-scheduler 1 // Move all the Region leaders on store 1 out
>> scheduler config evict-leader-scheduler // Display the stores in which the scheduler is located since v4.0.0
>> scheduler config evict-leader-scheduler add-store 2 // Add leader eviction scheduling for store 2
>> scheduler config evict-leader-scheduler delete-store 2 // Remove leader eviction scheduling for store 2
>> scheduler add shuffle-leader-scheduler // Randomly exchange the leader on different stores
>> scheduler add shuffle-region-scheduler // Randomly schedule the Regions on different stores
>> scheduler add evict-slow-store-scheduler // When there is one and only one slow store, evict all Region leaders of that store
>> scheduler remove grant-leader-scheduler-1 // Remove the corresponding scheduler, and `-1` corresponds to the store ID
>> scheduler pause balance-region-scheduler 10 // Pause the balance-region scheduler for 10 seconds
Expand Down Expand Up @@ -807,6 +809,24 @@ Usage:
>> scheduler config balance-hot-region-scheduler set enable-for-tiflash true
```

### `scheduler config evict-leader-scheduler`

Use this command to view and manage the configuration of the `evict-leader-scheduler`.

- When an `evict-leader-scheduler` already exists, use the `add-store` subcommand to add leader eviction scheduling for the specified store:

```bash
scheduler config evict-leader-scheduler add-store 2 // Add leader eviction scheduling for store 2
```

- When an `evict-leader-scheduler` already exists, use the `delete-store` subcommand to remove leader eviction scheduling for the specified store:

```bash
scheduler config evict-leader-scheduler delete-store 2 // Remove leader eviction scheduling for store 2
```

If all store configurations of an `evict-leader-scheduler` are removed, the scheduler itself is automatically removed.

### `store [delete | label | weight | remove-tombstone | limit ] <store_id> [--jq="<query string>"]`

Use this command to view the store information or remove a specified store. For a jq formatted output, see [jq-formatted-json-output-usage](#jq-formatted-json-output-usage).
Expand Down
Loading