1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-07 09:46:53 +01:00
Files
openshift-docs/modules/virt-about-node-maintenance.adoc
2022-08-01 17:23:44 +00:00

30 lines
2.0 KiB
Plaintext

// Module included in the following assemblies:
// virt/node_maintenance/virt-about-node-maintenance.adoc
:_content-type: CONCEPT
[id="virt-about-node-maintenance_{context}"]
= About node maintenance mode
Nodes can be placed into maintenance mode using the `oc adm` utility, or using `NodeMaintenance` custom resources (CRs).
[NOTE]
====
The `node-maintenance-operator` (NMO) is no longer shipped with {VirtProductName}. It is now available to deploy as a standalone Operator from the *OperatorHub* in the {product-title} web console, or by using the OpenShift CLI (`oc`).
====
Placing a node into maintenance marks the node as unschedulable and drains all the virtual machines and pods from it. Virtual machine instances that have a `LiveMigrate` eviction strategy are live migrated to another node without loss of service. This eviction strategy is configured by default in virtual machine created from common templates but must be configured manually for custom virtual machines.
Virtual machine instances without an eviction strategy are shut down. Virtual machines with a `RunStrategy` of `Running` or `RerunOnFailure` are recreated on another node. Virtual machines with a `RunStrategy` of `Manual` are not automatically restarted.
[IMPORTANT]
====
Virtual machines must have a persistent volume claim (PVC) with a shared `ReadWriteMany` (RWX) access mode to be live migrated.
====
When installed as part of {VirtProductName}, Node Maintenance Operator watches for new or deleted `NodeMaintenance` CRs. When a new `NodeMaintenance` CR is detected, no new workloads are scheduled and the node is cordoned off from the rest of the cluster. All pods that can be evicted are evicted from the node. When a `NodeMaintenance` CR is deleted, the node that is referenced in the CR is made available for new workloads.
[NOTE]
====
Using a `NodeMaintenance` CR for node maintenance tasks achieves the same results as the `oc adm cordon` and `oc adm drain` commands using standard {product-title} custom resource processing.
====