You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Machine Config Operator (MCO) uses a boot image to start a {op-system-first} node. By default, {product-title} does not manage the boot image.
10
-
11
-
This means that the boot image in your cluster is not updated along with your cluster. For example, if your cluster was originally created with {product-title} 4.12, the boot image that the cluster uses to create nodes is the same 4.12 version, even if your cluster is at a later version. If the cluster is later upgraded to 4.13 or later, new nodes continue to scale with the same 4.12 image.
12
-
13
-
This process could cause the following issues:
14
-
15
-
* Extra time to start nodes
16
-
* Certificate expiration issues
17
-
* Version skew issues
18
-
19
-
To avoid these issues, you can configure your cluster to update the boot image whenever you update your cluster. By modifying the `MachineConfiguration` object, you can enable this feature. Currently, the ability to update the boot image is available for only Google Cloud Platform (GCP) and Amazon Web Services (AWS) clusters. It is not supported for clusters managed by the {cluster-capi-operator}.
20
-
21
-
If you are not using the default user data secret, named `worker-user-data`, in your machine set, or you have modified the `worker-user-data` secret, you should not use managed boot image updates. This is because the Machine Config Operator (MCO) updates the machine set to use a managed version of the secret. By using the managed boot images feature, you are giving up the capability to customize the secret stored in the machine set object.
22
-
23
-
To view the current boot image used in your cluster, examine a machine set:
24
-
25
-
.Example machine set with the boot image reference
<1> This boot image is the same as the originally-installed {product-title} version, in this example {product-title} 4.12, regardless of the current version of the cluster. The way that the boot image is represented in the machine set depends on the platform, as the structure of the `providerSpec` field differs from platform to platform.
50
-
51
-
If you configure your cluster to update your boot images, the boot image referenced in your machine sets matches the current version of the cluster.
By default, for {gcp-first} and {aws-first} clusters, the Machine Config Operator (MCO) updates the boot image in the machine sets in your cluster whenever you update your cluster.
11
+
12
+
For {gcp-short} and {aws-short}, you can disable this default behavior, if needed. When disabled, the boot image no longer updates with the cluster. For example, with the default behavior disabled, if your cluster was originally created with {product-title} 4.16, the boot image that the MCO would use to create nodes is the same 4.16 version, even if your cluster is at a later version.
13
+
14
+
However, using an older boot image could cause the following issues:
15
+
16
+
* Extra time to start nodes
17
+
* Certificate expiration issues
18
+
* Version skew issues
19
+
20
+
For information on how to disable the default behavior, see "Disabling updated boot images". If you disable the default behavior, you can enable the default behavior at any time. For more information, see "Enabling updated boot images".
21
+
22
+
[NOTE]
23
+
====
24
+
The ability to configure this behavior is available for only {gcp-short} and {aws-short} clusters. It is not supported for clusters managed by the {cluster-capi-operator}.
25
+
====
26
+
27
+
How the cluster behaves after disabling or re-enabling the default behavior, depends upon when you made the change, including the following scenarios:
28
+
29
+
* If you disable the behavior before updating to a new {product-title} version:
30
+
** The boot image version used by the machine sets remains the same {product-title} version as when the feature was disabled.
31
+
** When you scale up nodes, the new nodes use that same {product-title} version.
32
+
33
+
* If you disable the behavior after updating to a new {product-title} version:
34
+
** The boot image version used by the machine sets is updated to match the updated {product-title} version.
35
+
** When you scale up nodes, the new nodes use the updated {product-title} version.
36
+
** If you update to a later {product-title} version, the boot image version in the machine sets remains at the current version and is not updated with the cluster.
37
+
38
+
* If you enable the behavior after disabling:
39
+
** The boot image version used by the machine sets is updated to the current {product-title} version, if different.
40
+
** When you scale up nodes, the new nodes use the current {product-title} version in the cluster.
41
+
42
+
[NOTE]
43
+
====
44
+
Because a boot image is used only when a node is scaled up, this feature has no effect on existing nodes.
45
+
====
46
+
47
+
To view the current boot image used in your cluster, examine a machine set:
48
+
49
+
.Example machine set with the boot image reference
<1> This boot image is the same as the originally-installed {product-title} version, in this example {product-title} 4.12, regardless of the current version of the cluster. The way that the boot image is represented in the machine set depends on the platform, as the structure of the `providerSpec` field differs from platform to platform.
74
+
75
+
// The following admonition is intended to address https://issues.redhat.com/browse//OSDOCS-14592
76
+
[IMPORTANT]
77
+
====
78
+
If any of the machine sets for which you want to enable updated boot images uses a `*-user-data` secret that is based on Ignition version 2.2.0, the Machine Config Operator converts the Ignition version to 3.4.0 when you enable updated boot images. {product-title} versions 4.5 and lower use Ignition version 2.2.0. If this conversion fails, the MCO or your cluster could degrade. An error message that includes _err: converting ignition stub failed: failed to parse Ignition config_ is added to the output of the `oc get ClusterOperator machine-config` command. You can use the following general steps to correct the problem:
79
+
80
+
. Disable updated boot images. For more information, see "Disabling updated boot images".
81
+
. Manually update the `*-user-data` secret to use Ignition version to 3.2.0.
82
+
. Enable updated boot images. For more information, see "Enabling updated boot images".
By default, {product-title} does not manage the boot image. You can configure your cluster to update the boot image whenever you update your cluster by modifying the `MachineConfiguration` object.
10
+
By default, for {gcp-first} and {aws-first} clusters, the Machine Config Operator (MCO) updates the boot image in the machine sets in your cluster whenever you update your cluster.
11
11
12
-
Currently, the ability to update the boot image is available for only Google Cloud Platform (GCP) and Amazon Web Services (AWS) clusters. It is not supported for clusters managed by the {cluster-capi-operator}.
12
+
If you disabled this default behavior, so that the boot images are not updated, you can revert to the default behavior by editing the `MachineConfiguration` object.
13
+
14
+
Enabling the default behavior updates the boot image to the current {product-title} version. If the cluster is again updated to a new {product-title} version in the future, the boot image is updated again. New nodes created after enabling the feature use the updated boot image. This feature has no effect on existing nodes.
13
15
14
16
.Procedure
15
17
16
-
. Edit the `MachineConfiguration` object, named `cluster`, to enable the updating of boot images by running the following command:
18
+
. Edit the `MachineConfiguration` object, named `cluster`, to enable the default boot image update behavior for some or all of your machine sets:
17
19
+
18
20
[source,terminal]
19
21
----
20
22
$ oc edit MachineConfiguration cluster
21
23
----
22
24
23
-
* Optional: Configure the boot image update feature for all the machine sets:
25
+
* Optional: Enable the default behavior for all machine sets:
24
26
+
25
27
[source,yaml]
26
28
----
@@ -33,15 +35,17 @@ spec:
33
35
# ...
34
36
managedBootImages: <1>
35
37
machineManagers:
36
-
- resource: machinesets
37
-
apiGroup: machine.openshift.io
38
+
- apiGroup: machine.openshift.io <2>
39
+
resource: machinesets <3>
38
40
selection:
39
-
mode: All <2>
41
+
mode: All <4>
40
42
----
41
-
<1> Activates the boot image update feature.
42
-
<2> Specifies that all the machine sets in the cluster are to be updated.
43
+
<1> Configures the boot image update feature.
44
+
<2> Specifies the API group. This must be `machine.openshift.io`.
45
+
<3> Specifies the resource within the specified API group to apply the change. This must be `machinesets`.
46
+
<4> Specifies that the default behavior is enabled for all machine sets in the cluster.
43
47
44
-
* Optional: Configure the boot image update feature for specific machine sets:
48
+
* Optional: Enable the default behavior for specific machine sets:
45
49
+
46
50
[source,yaml]
47
51
----
@@ -54,62 +58,34 @@ spec:
54
58
# ...
55
59
managedBootImages: <1>
56
60
machineManagers:
57
-
- resource: machinesets
58
-
apiGroup: machine.openshift.io
61
+
- apiGroup: machine.openshift.io <2>
62
+
resource: machinesets <3>
59
63
selection:
60
-
mode: Partial
64
+
mode: Partial <4>
61
65
partial:
62
66
machineResourceSelector:
63
67
matchLabels:
64
-
update-boot-image: "true" <2>
68
+
region: "east"
65
69
----
66
-
<1> Activates the boot image update feature.
67
-
<2> Specifies that any machine set with this label is to be updated.
70
+
<1> Configures the boot image update feature.
71
+
<2> Specifies the API group. This must be `machine.openshift.io`.
72
+
<3> Specifies the resource within the specified API group to apply the change. This must be `machinesets`.
73
+
<4> Specifies that the default behavior is enabled for machine sets with the specified label.
68
74
+
69
75
[TIP]
70
76
====
71
77
If an appropriate label is not present on the machine set, add a key-value pair by running a command similar to following:
<1> Status of the boot image update. {cluster-capi-operator} machine sets and machine deployments are not currently supported for boot image updates.
110
-
<2> Indicates if any boot image updates failed. If any of the updates fail, the Machine Config Operator is degraded. In this case, manual intervention might be required.
0 commit comments