Skip to content

Commit 632f4bd

Browse files
authored
Merge pull request #83849 from mburke5678/wmco-graceful-reboot-412
[enterprise-4.12] OSDOCS12386: Add graceful reboot module to WMCO docs
2 parents 4be04a5 + 5c2210b commit 632f4bd

File tree

2 files changed

+59
-1
lines changed

2 files changed

+59
-1
lines changed

modules/nodes-nodes-rebooting-gracefully.adoc

+52
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,21 @@
22
//
33
// * nodes/nodes-nodes-rebooting.adoc
44

5+
ifeval::["{context}" == "nodes-nodes-rebooting"]
6+
:nodes:
7+
endif::[]
8+
ifeval::["{context}" == "enabling-windows-container-workloads"]
9+
:windows:
10+
endif::[]
11+
512
:_mod-docs-content-type: PROCEDURE
613
[id="nodes-nodes-rebooting-gracefully_{context}"]
714
= Rebooting a node gracefully
815

16+
ifdef::windows[]
17+
The Windows Machine Config Operator (WMCO) minimizes node reboots whenever possible. However, certain operations and updates require a reboot to ensure that changes are applied correctly and securely. To safely reboot your Windows nodes, use the graceful reboot process. For information on gracefully rebooting a standard {product-title} node, see "Rebooting a node gracefully" in the Nodes documentation.
18+
endif::windows[]
19+
920
Before rebooting a node, it is recommended to backup etcd data to avoid any data loss on the node.
1021

1122
[NOTE]
@@ -48,6 +59,7 @@ In this case, run the drain command again, adding the `disable-eviction` flag, w
4859
$ oc adm drain <node1> --ignore-daemonsets --delete-emptydir-data --force --disable-eviction
4960
----
5061

62+
ifdef::nodes[]
5163
. Access the node in debug mode:
5264
+
5365
[source,terminal]
@@ -85,13 +97,52 @@ $ ssh core@<master-node>.<cluster_name>.<base_domain>
8597
$ sudo systemctl reboot
8698
----
8799
====
100+
endif::nodes[]
101+
ifdef::windows[]
102+
. SSH into the Windows node and enter PowerShell by running the following command:
103+
+
104+
[source,terminal]
105+
----
106+
C:\> powershell
107+
----
108+
109+
. Restart the node by running the following command:
110+
+
111+
[source,terminal]
112+
----
113+
C:\> Restart-Computer -Force
114+
----
115+
116+
. Windows nodes on Amazon Web Services (AWS) do not return to `READY` state after a graceful reboot due to an inconsistency with the EC2 instance metadata routes and the Host Network Service (HNS) networks.
117+
+
118+
After the reboot, SSH into any Windows node on AWS and add the route by running the following command in a shell prompt:
119+
+
120+
[source,terminal]
121+
----
122+
C:\> route add 169.254.169.254 mask 255.255.255.0 <gateway_ip>
123+
----
124+
+
125+
where:
126+
+
127+
--
128+
`169.254.169.254`:: Specifies the address of the EC2 instance metadata endpoint.
129+
`255.255.255.255`:: Specifies the network mask of the EC2 instance metadata endpoint.
130+
`<gateway_ip>`:: Specifies the corresponding IP address of the gateway in the Windows instance, which you can find by running the following command:
131+
+
132+
[source,terminal]
133+
----
134+
C:\> ipconfig | findstr /C:"Default Gateway"
135+
----
136+
--
137+
endif::windows[]
88138
89139
. After the reboot is complete, mark the node as schedulable by running the following command:
90140
+
91141
[source,terminal]
92142
----
93143
$ oc adm uncordon <node1>
94144
----
145+
ifdef::nodes[]
95146
+
96147
[NOTE]
97148
====
@@ -107,6 +158,7 @@ $ ssh core@<target_node>
107158
$ sudo oc adm uncordon <node> --kubeconfig /etc/kubernetes/static-pod-resources/kube-apiserver-certs/secrets/node-kubeconfigs/localhost.kubeconfig
108159
----
109160
====
161+
endif::nodes[]
110162
111163
. Verify that the node is ready:
112164
+

windows_containers/enabling-windows-container-workloads.adoc

+7-1
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,14 @@ include::modules/wmco-cluster-wide-proxy.adoc[leveloffset=+1]
6161
* xref:../networking/enable-cluster-wide-proxy.adoc#enable-cluster-wide-proxy[Configuring the cluster-wide proxy].
6262

6363

64+
include::modules/nodes-nodes-rebooting-gracefully.adoc[leveloffset=+1]
65+
66+
.Additional references
67+
* xref:../nodes/nodes/nodes-nodes-rebooting.adoc#nodes-nodes-rebooting-gracefully_nodes-nodes-rebooting[Rebooting a {product-title} node gracefully]
68+
* xref:../backup_and_restore/control_plane_backup_and_restore/backing-up-etcd.adoc#backup-etcd[Backing up etcd data]
69+
6470
[role="_additional-resources"]
6571
== Additional resources
6672

6773
* xref:../installing/installing_azure/installing-azure-default.adoc#ssh-agent-using_installing-azure-default[Generating a key pair for cluster node SSH access]
68-
* xref:../operators/admin/olm-adding-operators-to-cluster.adoc#olm-adding-operators-to-a-cluster[Adding Operators to a cluster].
74+
* xref:../operators/admin/olm-adding-operators-to-cluster.adoc#olm-adding-operators-to-a-cluster[Adding Operators to a cluster]

0 commit comments

Comments
 (0)