Skip to content

Commit 9852848

Browse files
author
Michael Burke
committed
On Cluster Layering: Make it easier to see errors
1 parent 9d5d16e commit 9852848

File tree

2 files changed

+33
-2
lines changed

2 files changed

+33
-2
lines changed

modules/coreos-layering-configuring-on-proc.adoc

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,37 @@ machine-os-builder-6fb66cfb99-zcpvq 1/1
130130
<1> This is the build pod where the custom layered image is building, named in the `build-<MachineOSConfig_CR_name>-<hash>` format.
131131
<2> This pod can be used for troubleshooting.
132132

133+
. Verify the custom layered image build by running a command similar to the following:
134+
+
135+
[source,terminal]
136+
----
137+
$ oc get machineconfigpool <mcp_name> -o yaml
138+
----
139+
+
140+
.Example output
141+
[source,terminal]
142+
----
143+
apiVersion: machineconfiguration.openshift.io/v1
144+
kind: MachineConfigPool
145+
metadata:
146+
labels:
147+
machineconfiguration.openshift.io/mco-built-in: ""
148+
pools.operator.machineconfiguration.openshift.io/layered: ""
149+
name: layered
150+
# ...
151+
status:
152+
# ...
153+
conditions
154+
# ...
155+
- lastTransitionTime: "2025-09-09T13:43:35Z"
156+
message: 'Failed to build OS image for pool worker (MachineOSBuild: worker-2d03dc921ff0c242c5892a3ef1ed1608):
157+
Failed: Build Failed'
158+
reason: BuildFailed
159+
status: "True" <1>
160+
type: ImageBuildDegraded
161+
----
162+
<1> Indicates whether the custom layered image build failed. If `False`, the build succeeded. If `True`, the build failed. You can use the build pod logs to troubleshoot any build failures.
163+
133164
. Verify the current stage of your layered build by running the following command:
134165
+
135166
[source,terminal]
@@ -141,7 +172,7 @@ $ oc get machineosbuilds
141172
[source,terminal]
142173
----
143174
NAME PREPARED BUILDING SUCCEEDED INTERRUPTED FAILED AGE
144-
layered-image-ad5a3cad36303c363cf458ab0524e7c0 False True False False False 12m <1>
175+
layered-image-ad5a3cad36303c363cf458ab0524e7c0 False True False False False 12m <1>
145176
----
146177
<1> The `MachineOSBuild` is named in the `<MachineOSConfig_CR_name>-<hash>` format.
147178

modules/coreos-layering-configuring-on.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ For {sno} clusters, you can apply a custom layered image to the control plane no
5858

5959
include::snippets//coreos-layering-configuring-on-pause.adoc[]
6060

61-
In the case of a build failure, for example due to network issues or an invalid secret, the MCO retries the build three additional times before the job fails. The MCO creates a different build pod for each build attempt. You can use the build pod logs to troubleshoot any build failures. Note that the MCO automatically removes these build pods after a short period of time.
61+
In the case of a build failure, for example due to network issues or an invalid secret, the MCO retries the build three additional times before the job fails. The MCO creates a different build pod for each build attempt. Note that the MCO automatically removes these build pods after a short period of time. Also, the affected machine config pool reports a build failure through the `ImageBuildDegraded` status condition. You can use the build pod logs to troubleshoot any build failures.
6262

6363
.Example failed `MachineOSBuild` object
6464
[source,terminal]

0 commit comments

Comments
 (0)