Skip to content

Commit 875e245

Browse files
authored
Merge pull request #51545 from mburke5678/BZ1937814-mcp-status-description
BZ1937814: MCP transitions to UPDATING and READYMACHINECOUNT decrements on cordon
2 parents 94b5e1b + 6c338c8 commit 875e245

File tree

1 file changed

+88
-22
lines changed

1 file changed

+88
-22
lines changed

modules/checking-mco-status.adoc

Lines changed: 88 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -6,43 +6,64 @@
66
[id="checking-mco-status_{context}"]
77
= Checking machine config pool status
88

9-
To see the status of the Machine Config Operator, its sub-components, and the resources it manages, use the following `oc` commands:
9+
To see the status of the Machine Config Operator (MCO), its sub-components, and the resources it manages, use the following `oc` commands:
1010

1111
.Procedure
12-
. To see the number of MCO-managed nodes available on your cluster for each pool, type:
12+
. To see the number of MCO-managed nodes available on your cluster for each machine config pool (MCP), run the following command:
1313
+
1414
[source,terminal]
1515
----
1616
$ oc get machineconfigpool
17-
NAME CONFIG UPDATED UPDATING DEGRADED MACHINECOUNT READYMACHINECOUNT UPDATEDMACHINECOUNT DEGRADEDMACHINECOUNT AGE
18-
master rendered-master-dd… True False False 3 3 3 0 4h42m
19-
worker rendered-worker-fde… True False False 3 3 3 0 4h42m
2017
----
2118
+
22-
In the previous output, there are three master and three worker nodes. All machines are updated and none are currently updating. Because all nodes are `Updated` and `Ready` and none are `Degraded`, you can tell that there are no issues.
19+
.Example output
20+
[source,terminal]
21+
----
22+
NAME CONFIG UPDATED UPDATING DEGRADED MACHINECOUNT READYMACHINECOUNT UPDATEDMACHINECOUNT DEGRADEDMACHINECOUNT AGE
23+
master rendered-master-06c9c4… True False False 3 3 3 0 4h42m
24+
worker rendered-worker-f4b64… False True False 3 2 2 0 4h42m
25+
----
26+
+
27+
--
28+
where:
2329

24-
. To see each existing `machineconfig`, type:
30+
UPDATED:: The `True` status indicates that the MCO has applied the current machine config to the nodes in that MCP. The current machine config is specified in the `STATUS` field in the `oc get mcp` output. The `False` status indicates a node in the MCP is updating.
31+
UPDATING:: The `True` status indicates that the MCO is applying the desired machine config, as specified in the `MachineConfigPool` custom resource, to at least one of the nodes in that MCP. The desired machine config is the new, edited machine config. Nodes that are updating might not be available for scheduling. The `False` status indicates that all nodes in the MCP are updated.
32+
DEGRADED:: A `True` status indicates the MCO is blocked from applying the current or desired machine config to at least one of the nodes in that MCP, or the configuration is failing. Nodes that are degraded might not be available for scheduling. A `False` status indicates that all nodes in the MCP are ready.
33+
MACHINECOUNT:: Indicates the total number of machines in that MCP.
34+
READYMACHINECOUNT:: Indicates the total number of machines in that MCP that are ready for scheduling.
35+
UPDATEDMACHINECOUNT:: Indicates the total number of machines in that MCP that have the current machine config.
36+
DEGRADEDMACHINECOUNT:: Indicates the total number of machines in that MCP that are marked as degraded or unreconcilable.
37+
--
2538
+
39+
In the previous output, there are three control plane (master) nodes and three worker nodes. The control plane MCP and the associated nodes are updated to the current machine config. The nodes in the worker MCP are being updated to the desired machine config. Two of the nodes in the worker MCP are updated and one is still updating, as indicated by the `UPDATEDMACHINECOUNT` being `2`. There are no issues, as indicated by the `DEGRADEDMACHINECOUNT` being `0` and `DEGRADED` being `False`.
40+
+
41+
While the nodes in the MCP are updating, the machine config listed under `CONFIG` is the current machine config, which the MCP is being updated from. When the update is complete, the listed machine config is the desired machine config, which the MCP was updated to.
42+
+
43+
[NOTE]
44+
====
45+
If a node is being cordoned, that node is not included in the `READYMACHINECOUNT`, but is included in the `MACHINECOUNT`. Also, the MCP status is set to `UPDATING`. Because the node has the current machine config, it is counted in the `UPDATEDMACHINECOUNT` total:
46+
47+
.Example output
2648
[source,terminal]
2749
----
28-
$ oc get machineconfigs
29-
NAME GENERATEDBYCONTROLLER IGNITIONVERSION AGE
30-
00-master 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
31-
00-worker 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
32-
01-master-container-runtime 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
33-
01-master-kubelet 2c9371fbb673b97a6fe8b1c52… 3.2.0 5h18m
34-
...
35-
rendered-master-dde... 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
36-
rendered-worker-fde... 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
50+
NAME CONFIG UPDATED UPDATING DEGRADED MACHINECOUNT READYMACHINECOUNT UPDATEDMACHINECOUNT DEGRADEDMACHINECOUNT AGE
51+
master rendered-master-06c9c4… True False False 3 3 3 0 4h42m
52+
worker rendered-worker-c1b41a… False True False 3 2 3 0 4h42m
3753
----
38-
+
39-
Note that the `machineconfigs` listed as `rendered` are not meant to be changed or deleted. Expect them to be hidden at some point in the future.
54+
====
4055
41-
. Check the status of worker (or change to master) to see the status of that pool of nodes:
56+
. To check the status of the nodes in an MCP by examining the `MachineConfigPool` custom resource, run the following command:
57+
:
4258
+
4359
[source,terminal]
4460
----
4561
$ oc describe mcp worker
62+
----
63+
+
64+
.Example output
65+
[source,terminal]
66+
----
4667
...
4768
Degraded Machine Count: 0
4869
Machine Count: 3
@@ -52,13 +73,58 @@ $ oc describe mcp worker
5273
Updated Machine Count: 3
5374
Events: <none>
5475
----
76+
+
77+
[NOTE]
78+
====
79+
If a node is being cordoned, the node is not included in the `Ready Machine Count`. It is included in the `Unavailable Machine Count`:
5580

56-
. You can view the contents of a particular machine config (in this case, `01-master-kubelet`). The trimmed output from the following `oc describe` command shows that this `machineconfig` contains both configuration files (`cloud.conf` and `kubelet.conf`) and a systemd service
57-
(Kubernetes Kubelet):
81+
.Example output
82+
[source,terminal]
83+
----
84+
...
85+
Degraded Machine Count: 0
86+
Machine Count: 3
87+
Observed Generation: 2
88+
Ready Machine Count: 2
89+
Unavailable Machine Count: 1
90+
Updated Machine Count: 3
91+
----
92+
====
93+
94+
. To see each existing `MachineConfig` object, run the following command:
95+
+
96+
[source,terminal]
97+
----
98+
$ oc get machineconfigs
99+
----
100+
+
101+
.Example output
102+
[source,terminal]
103+
----
104+
NAME GENERATEDBYCONTROLLER IGNITIONVERSION AGE
105+
00-master 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
106+
00-worker 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
107+
01-master-container-runtime 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
108+
01-master-kubelet 2c9371fbb673b97a6fe8b1c52… 3.2.0 5h18m
109+
...
110+
rendered-master-dde... 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
111+
rendered-worker-fde... 2c9371fbb673b97a6fe8b1c52... 3.2.0 5h18m
112+
----
113+
+
114+
Note that the `MachineConfig` objects listed as `rendered` are not meant to be changed or deleted.
115+
116+
. To view the contents of a particular machine config (in this case, `01-master-kubelet`), run the following command:
58117
+
59118
[source,terminal]
60119
----
61120
$ oc describe machineconfigs 01-master-kubelet
121+
----
122+
+
123+
The output from the command shows that this `MachineConfig` object contains both configuration files (`cloud.conf` and `kubelet.conf`) and a systemd service (Kubernetes Kubelet):
124+
+
125+
.Example output
126+
[source,terminal]
127+
----
62128
Name: 01-master-kubelet
63129
...
64130
Spec:
@@ -89,7 +155,7 @@ ExecStart=/usr/bin/hyperkube \
89155
--config=/etc/kubernetes/kubelet.conf \ ...
90156
----
91157
92-
If something goes wrong with a machine config that you apply, you can always back out that change. For example, if you had run `oc create -f ./myconfig.yaml` to apply a machine config, you could remove that machine config by typing:
158+
If something goes wrong with a machine config that you apply, you can always back out that change. For example, if you had run `oc create -f ./myconfig.yaml` to apply a machine config, you could remove that machine config by running the following command:
93159
94160
[source,terminal]
95161
----

0 commit comments

Comments
 (0)