-
Notifications
You must be signed in to change notification settings - Fork 1.8k
CNV#62399: 4.20 Descheduler profile doc #98815
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
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,76 @@ | ||
| // Module included in the following assemblies: | ||
| // | ||
| // virt/virtual_machines/advanced_vm_management/virt-enabling-descheduler-evictions.adoc | ||
|
|
||
| :_mod-docs-content-type: PROCEDURE | ||
| [id="virt-configuring-descheduler-evictions_{context}"] | ||
| = Configuring descheduler evictions for virtual machines | ||
|
|
||
| After the descheduler is installed and configured, all migratable virtual machines (VMs) are eligible for eviction by default. You can configure the descheduler to manage VM evictions across the cluster and optionally exclude specific VMs from eviction. | ||
|
|
||
| .Prerequisites | ||
|
|
||
| * Install the descheduler in the {product-title} web console or OpenShift CLI (`oc`). | ||
|
|
||
| .Procedure | ||
|
|
||
| . Stop the VM. | ||
|
|
||
| . Configure the `KubeDescheduler` object with the `KubeVirtRelieveAndMigrate` profile and enable background evictions for improved VM eviction stability during live migration: | ||
danielclowers marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| + | ||
| [source,yaml] | ||
| ---- | ||
| apiVersion: operator.openshift.io/v1 | ||
| kind: KubeDescheduler | ||
| metadata: | ||
| name: cluster | ||
| namespace: openshift-kube-descheduler-operator | ||
| spec: | ||
| deschedulingIntervalSeconds: 60 | ||
danielclowers marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| profiles: | ||
| - KubeVirtRelieveAndMigrate | ||
| mode: Automatic | ||
| ---- | ||
| + | ||
| . Optional: To evict pods, set the `mode` field value to `Automatic`. By default, the descheduler does not evict pods. | ||
|
|
||
| . Optional: Configure limits for the number of parallel evictions to improve stability in large clusters. | ||
| + | ||
| The descheduler can limit the number of concurrent evictions per node and across the cluster by using the `evictionLimits` field. Set these limits to match the migration limits configured in the `HyperConverged` custom resource (CR). | ||
| + | ||
| [source,yaml] | ||
| ---- | ||
| spec: | ||
| evictionLimits: | ||
| node: 2 | ||
| total: 5 | ||
| ---- | ||
| + | ||
| Set values that correspond to the migration limits in the `HyperConverged` CR: | ||
| + | ||
| [source,yaml] | ||
| ---- | ||
| spec: | ||
| liveMigrationConfig: | ||
| parallelMigrationsPerCluster: 5 | ||
| parallelOutboundMigrationsPerNode: 2 | ||
| ---- | ||
|
|
||
| . Optional: To exclude the VM from eviction, add the `descheduler.alpha.kubernetes.io/prefer-no-eviction` annotation to the `spec.template.metadata.annotations` field. The change is applied dynamically and is propagated to the `VirtualMachineInstance` (VMI) object and the `virt-launcher` pod. | ||
| + | ||
| Only the presence of the annotation is checked. The value is not evaluated, so `"true"` and `"false"` have the same effect. | ||
| + | ||
| [source,yaml] | ||
| ---- | ||
| apiVersion: kubevirt.io/v1 | ||
| kind: VirtualMachine | ||
| spec: | ||
| template: | ||
| metadata: | ||
| annotations: | ||
| descheduler.alpha.kubernetes.io/prefer-no-eviction: "true" | ||
| ---- | ||
|
|
||
| . Start the VM. | ||
danielclowers marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| The VM is now configured according to the descheduler settings. | ||
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.