1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-07 00:48:01 +01:00
Files
openshift-docs/modules/virt-about-ksm.adoc
2024-02-14 21:19:59 +00:00

44 lines
1.9 KiB
Plaintext

// Module included in the following assembly:
//
// * virt/virtual_machines/advanced_vm_management/virt-activating-ksm.adoc
//
:_mod-docs-content-type: CONCEPT
[id="virt-about-ksm_{context}"]
= About using {VirtProductName} to activate KSM
You can configure {VirtProductName} to activate kernel samepage merging (KSM) when nodes experience memory overload.
[id="virt-ksm-configuration-methods"]
== Configuration methods
You can enable or disable the KSM activation feature for all nodes by using the {product-title} web console or by editing the `HyperConverged` custom resource (CR). The `HyperConverged` CR supports more granular configuration.
[discrete]
[id="virt-ksm-cr-configuration"]
=== CR configuration
You can configure the KSM activation feature by editing the `spec.configuration.ksmConfiguration` stanza of the `HyperConverged` CR.
* You enable the feature and configure settings by editing the `ksmConfiguration` stanza.
* You disable the feature by deleting the `ksmConfiguration` stanza.
* You can allow {VirtProductName} to enable KSM on only a subset of nodes by adding node selection syntax to the `ksmConfiguration.nodeLabelSelector` field.
[NOTE]
====
Even if the KSM activation feature is disabled in {VirtProductName}, an administrator can still enable KSM on nodes that support it.
====
[id="virt-ksm-node-labels"]
== KSM node labels
{VirtProductName} identifies nodes that are configured to support KSM and applies the following node labels:
`kubevirt.io/ksm-handler-managed: "false"`:: This label is set to `"true"` when {VirtProductName} activates KSM on a node that is experiencing memory overload. This label is not set to `"true"` if an administrator activates KSM.
`kubevirt.io/ksm-enabled: "false"`:: This label is set to `"true"` when KSM is activated on a node, even if {VirtProductName} did not activate KSM.
These labels are not applied to nodes that do not support KSM.