Skip to content

Commit fed5de3

Browse files
authored
Merge pull request #73909 from xJustin/OSDOCS-9915-machine-pool-grace-period
OSDOCS-9915 machine pool grace periods during upgrades
2 parents 47e1254 + d4095d9 commit fed5de3

File tree

4 files changed

+90
-1
lines changed

4 files changed

+90
-1
lines changed

modules/rosa-edit-objects.adoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,6 +230,9 @@ $ rosa edit machinepool --cluster=<cluster_name> | <cluster_id> <machinepool_ID>
230230
|--min-replicas
231231
|Specifies the minimum number of compute nodes when enabling autoscaling.
232232

233+
|--node-drain-grace-period
234+
|Specifies the node drain grace period when upgrading or replacing the machine pool. (This is for {hcp-title} clusters only.)
235+
233236
|--replicas
234237
|Required when autoscaling is not configured. The number (integer) of machines for this machine pool.
235238

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * rosa_cluster_admin/rosa_nodes/rosa-managing-worker-nodes.adoc
4+
//this module applies to ROSA HCP only
5+
6+
:_mod-docs-content-type: PROCEDURE
7+
[id="rosa-node-drain-grace-period_{context}"]
8+
= Configuring node drain grace periods in {hcp-title} clusters
9+
10+
You can configure the node drain grace period for machine pools in your cluster. The node drain grace period for a machine pool is how long the cluster respects the Pod Disruption Budget protected workloads when upgrading or replacing the machine pool. After this grace period, all remaining workloads are forcibly evicted. The value range for the node drain grace period is from `0` to `1 week`. With the default value `0`, or empty value, the machine pool drains without any time limitation until complete.
11+
12+
13+
.Prerequisites
14+
15+
* You installed and configured the latest {product-title} (ROSA) CLI, `rosa`, on your workstation.
16+
* You created a {hcp-title-first} cluster.
17+
* You have an existing machine pool.
18+
19+
.Procedure
20+
21+
. List all of the machine pools in the cluster by running the following command:
22+
+
23+
[source,terminal]
24+
----
25+
$ rosa list machinepools --cluster=<cluster_name>
26+
----
27+
+
28+
.Example output
29+
[source,terminal]
30+
----
31+
ID AUTOSCALING REPLICAS INSTANCE TYPE [...] AVAILABILITY ZONES SUBNET VERSION AUTOREPAIR TUNING CONFIGS
32+
workers No 2 m5.xlarge [...] us-east-1a N/A 4.14.18 Yes
33+
db-nodes-mp No 2 m5.xlarge [...] us-east-1a No 4.14.18 Yes
34+
----
35+
36+
. Check the node drain grace period for a machine pool by running the following command:
37+
+
38+
[source,terminal]
39+
----
40+
$ rosa describe machinepool --cluster <cluster_name> <machinepool_name>
41+
----
42+
+
43+
.Example output
44+
[source,terminal]
45+
----
46+
ID: workers
47+
Cluster ID: 2a90jdl0i4p9r9k9956v5ocv40se1kqs
48+
Node drain grace period: <1>
49+
----
50+
+
51+
<1> If this value is empty, the machine pool drains without any time limitation until complete.
52+
53+
. Optional: Update the node drain grace period for a machine pool by running the following command:
54+
+
55+
[source,terminal]
56+
----
57+
$ rosa edit machinepool --node-drain-grace-period="<node_drain_grace_period_value>" --cluster=<cluster_name> <machinepool_name>
58+
----
59+
+
60+
[NOTE]
61+
====
62+
Changing the node drain grace period during a machine pool upgrade applies to future upgrades, not in progress upgrades.
63+
====
64+
65+
.Verification
66+
67+
. Check the node drain grace period for a machine pool by running the following command:
68+
+
69+
[source,terminal]
70+
----
71+
$ rosa describe machinepool --cluster <cluster_name> <machinepool_name>
72+
----
73+
+
74+
.Example output
75+
[source,terminal]
76+
----
77+
ID: workers
78+
Cluster ID: 2a90jdl0i4p9r9k9956v5ocv40se1kqs
79+
Node drain grace period: 30 minutes
80+
----
81+
82+
. Verify the correct `Node drain grace period` for your machine pool in the output.

rosa_cluster_admin/rosa_nodes/rosa-managing-worker-nodes.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@ include::modules/rosa-adding-node-labels.adoc[leveloffset=+2]
5656
include::modules/rosa-adding-taints.adoc[leveloffset=+1]
5757
include::modules/rosa-adding-taints-ocm.adoc[leveloffset=+2]
5858
include::modules/rosa-adding-taints-cli.adoc[leveloffset=+2]
59-
6059
include::modules/rosa-adding-tuning.adoc[leveloffset=+1]
60+
include::modules/rosa-node-drain-grace-period.adoc[leveloffset=+1]
6161

6262
== Additional resources
6363
* xref:../../rosa_cluster_admin/rosa_nodes/rosa-nodes-machinepools-about.adoc#rosa-nodes-machinepools-about[About machine pools]

rosa_release_notes/rosa-release-notes.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@ For more information on region availabilities, see xref:../rosa_architecture/ros
3232

3333
* **Node management improvements.** Now, you can perform specific tasks to make clusters more efficient. You can cordon, uncordon, and drain a specific node. For more information, see xref:../nodes/nodes/nodes-nodes-working.adoc[Working with nodes].
3434

35+
* **Node drain grace periods.** You can now configure node drain grace periods in {hcp-title-first} clusters with the `rosa` CLI.
36+
+
37+
For more information about configuring node drain grace periods, see xref:../rosa_cluster_admin/rosa_nodes/rosa-managing-worker-nodes.adoc#rosa-node-drain-grace-period_rosa-managing-worker-nodes[Configuring node drain grace periods in {hcp-title-first}].
38+
3539
[id="rosa-q1-2024_{context}"]
3640
=== Q1 2024
3741

0 commit comments

Comments
 (0)