Skip to content

Commit d5016a9

Browse files
author
Bob Furu
authored
Merge pull request #39195 from bobfuru/BZ2010870
2 parents 520d129 + 1de8425 commit d5016a9

File tree

2 files changed

+69
-2
lines changed

2 files changed

+69
-2
lines changed
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * post_installation_configuration/machine-configuration-tasks.adoc
4+
5+
[id="rhcos-load-firmware-blobs_{context}"]
6+
= Loading custom firmware blobs in the machine config manifest
7+
8+
Because the default location for firmware blobs in `/usr/lib` is read-only, you can locate a custom firmware blob by updating the search path. This enables you to load local firmware blobs in the machine config manifest when the blobs are not managed by {op-system}.
9+
10+
.Procedure
11+
12+
. Create a Butane config file, `98-worker-firmware-blob.bu`, that updates the search path so that it is root-owned and writable to local storage. The following example places the custom blob file from your local workstation onto nodes under `/var/lib/firmware`.
13+
+
14+
[NOTE]
15+
====
16+
See "Creating machine configs with Butane" for information about Butane.
17+
====
18+
.Butane config file for custom firmware blob
19+
+
20+
[source,yaml]
21+
----
22+
variant: openshift
23+
version: 4.9.0
24+
metadata:
25+
labels:
26+
machineconfiguration.openshift.io/role: worker
27+
name: 98-worker-firmware-blob
28+
storage:
29+
files:
30+
- path: /var/lib/firmware/<package_name> <1>
31+
contents:
32+
local: <package_name> <2>
33+
mode: 0644 <3>
34+
openshift:
35+
kernel_arguments:
36+
- 'firmware_class.path=/var/lib/firmware' <4>
37+
----
38+
+
39+
<1> Sets the path on the node where the firmware package is copied to.
40+
<2> Specifies a file with contents that are read from a local file directory on the system running Butane. The path of the local file is relative to a `files-dir` directory, which must be specified by using the `--files-dir` option with Butane in the following step.
41+
<3> Sets the permissions for the file on the {op-system} node. It is recommended to set `0644` permissions.
42+
<4> The `firmware_class.path` parameter customizes the kernel search path of where to look for the custom firmware blob that was copied from your local workstation onto the root file system of the node. This example uses `/var/lib/firmware` as the customized path.
43+
44+
. Run Butane to generate a `MachineConfig` object file that uses a copy of the firmware blob on your local workstation named `98-worker-firmware-blob.yaml`. The firmware blob contains the configuration to be delivered to the nodes. The following example uses the `--files-dir` option to specify the directory on your workstation where the local file or files are located:
45+
+
46+
[source,terminal]
47+
----
48+
$ butane 98-worker-firmware-blob.bu -o 98-worker-firmware-blob.yaml --files-dir <directory_including_package_name>
49+
----
50+
. Apply the configurations to the nodes in one of two ways:
51+
+
52+
* If the cluster is not running yet, after you generate manifest files, add the `MachineConfig` object file to the `<installation_directory>/openshift` directory, and then continue to create the cluster.
53+
+
54+
* If the cluster is already running, apply the file:
55+
+
56+
[source,terminal]
57+
----
58+
$ oc apply -f 98-worker-firmware-blob.yaml
59+
----
60+
+
61+
A `MachineConfig` object YAML file is created for you to finish configuring your machines.
62+
+
63+
. Save the Butane config in case you need to update the `MachineConfig` object in the future.

post_installation_configuration/machine-configuration-tasks.adoc

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,11 @@ link:https://access.redhat.com/solutions/4510281[updating] SSH authorized keys,
2929

3030
There might be situations where the configuration on a node does not fully match what the currently-applied machine config specifies. This state is called _configuration drift_. The Machine Config Daemon (MCD) regularly checks the nodes for configuration drift. If the MCD detects configuration drift, the MCO marks the node `degraded` until an administrator corrects the node configuration. A degraded node is online and operational, but, it cannot be updated. For more information on configuration drift, see xref:../post_installation_configuration/machine-configuration-tasks.adoc#machine-config-drift-detection_post-install-machine-configuration-tasks[Understanding configuration drift detection].
3131

32+
[TIP]
33+
====
34+
Use the following "Configuring chrony time service" procedure as a model for how to go about adding other configuration files to {product-title} nodes.
35+
====
36+
3237
include::modules/installation-special-config-chrony.adoc[leveloffset=+2]
3338
include::modules/cnf-disable-chronyd.adoc[leveloffset=+2]
3439
include::modules/nodes-nodes-kernel-arguments.adoc[leveloffset=+2]
@@ -42,8 +47,7 @@ include::modules/nodes-nodes-cgroups-2.adoc[leveloffset=+2]
4247
include::modules/nodes-nodes-rtkernel-arguments.adoc[leveloffset=+2]
4348
include::modules/machineconfig-modify-journald.adoc[leveloffset=+2]
4449
include::modules/rhcos-add-extensions.adoc[leveloffset=+2]
45-
46-
Use the "Configuring chrony time service" section as a model for how to go about adding other configuration files to {product-title} nodes.
50+
include::modules/rhcos-load-firmware-blobs.adoc[leveloffset=+2]
4751

4852
[id="configuring-machines-with-custom-resources"]
4953
== Configuring MCO-related custom resources

0 commit comments

Comments
 (0)