Skip to content

Commit 7347446

Browse files
authored
Merge pull request #70125 from mletalie/OSDOCS-9251
[OSDOCS-9251]: Remove references to 'machineconfigpools' from NTO on ROSA with HCP docs
2 parents 8a82474 + 8475780 commit 7347446

File tree

1 file changed

+18
-14
lines changed

1 file changed

+18
-14
lines changed

modules/custom-tuning-specification.adoc

Lines changed: 18 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -134,12 +134,11 @@ ifdef::rosa-hcp-tuning[]
134134
"recommend": [
135135
{
136136
"profile": <tuned_profile_name>, <1>
137-
"priority": <priority>, <2>
138-
"machineConfigLabels": { <Key_Pair_for_MachineConfig> <3>
137+
"priority":{ <priority>, <2>
139138
},
140-
"match": [ <4>
139+
"match": [ <3>
141140
{
142-
"label": <label_information> <5>
141+
"label": <label_information> <4>
143142
},
144143
]
145144
},
@@ -148,9 +147,8 @@ ifdef::rosa-hcp-tuning[]
148147
----
149148
<1> A TuneD profile to apply on a match. For example `tuned_profile_1`.
150149
<2> Profile ordering priority. Lower numbers mean higher priority (`0` is the highest priority).
151-
<3> Optional: A dictionary of key-value pairs `MachineConfig` labels. The keys must be unique.
152-
<4> If omitted, profile match is assumed unless a profile with a higher priority matches first or `machineConfigLabels` is set.
153-
<5> The label for the profile matched items.
150+
<3> If omitted, profile match is assumed unless a profile with a higher priority matches first.
151+
<4> The label for the profile matched items.
154152
endif::[]
155153

156154
`<match>` is an optional list recursively defined as follows:
@@ -181,6 +179,7 @@ ifdef::rosa-hcp-tuning[]
181179
endif::[]
182180

183181
If `<match>` is not omitted, all nested `<match>` sections must also evaluate to `true`. Otherwise, `false` is assumed and the profile with the respective `<match>` section will not be applied or recommended. Therefore, the nesting (child `<match>` sections) works as logical AND operator. Conversely, if any item of the `<match>` list matches, the entire `<match>` list evaluates to `true`. Therefore, the list acts as logical OR operator.
182+
ifndef::rosa-hcp-tuning[]
184183

185184
If `machineConfigLabels` is defined, machine config pool based matching is turned on for the given `recommend:` list item. `<mcLabels>` specifies the labels for a machine config. The machine config is created automatically to apply host settings, such as kernel boot parameters, for the profile `<tuned_profile_name>`. This involves finding all machine config pools with machine config selector matching `<mcLabels>` and setting the profile `<tuned_profile_name>` on all nodes that are assigned the found machine config pools. To target nodes that have both master and worker roles, you must use the master role.
186185

@@ -190,7 +189,7 @@ The list items `match` and `machineConfigLabels` are connected by the logical OR
190189
====
191190
When using machine config pool based matching, it is advised to group nodes with the same hardware configuration into the same machine config pool. Not following this practice might result in TuneD operands calculating conflicting kernel parameters for two or more nodes sharing the same machine config pool.
192191
====
193-
192+
endif::rosa-hcp-tuning[]
194193
.Example: Node or pod label based matching
195194

196195
ifndef::rosa-hcp-tuning[]
@@ -263,8 +262,8 @@ Finally, the profile `openshift-node` has the lowest priority of `30`. It lacks
263262

264263
image::node-tuning-operator-workflow-revised.png[Decision workflow]
265264

266-
.Example: Machine config pool based matching
267265
ifndef::rosa-hcp-tuning[]
266+
.Example: Machine config pool based matching
268267
[source,yaml]
269268
----
270269
apiVersion: tuned.openshift.io/v1
@@ -290,6 +289,7 @@ spec:
290289
----
291290
endif::rosa-hcp-tuning[]
292291
ifdef::rosa-hcp-tuning[]
292+
.Example: Machine pool based matching
293293
[source,JSON]
294294
----
295295
{
@@ -308,9 +308,6 @@ ifdef::rosa-hcp-tuning[]
308308
],
309309
"recommend": [
310310
{
311-
"machineConfigLabels": {
312-
"machineconfiguration.openshift.io/role": "worker-custom"
313-
},
314311
"priority": 20,
315312
"profile": "openshift-node-custom"
316313
}
@@ -320,8 +317,9 @@ ifdef::rosa-hcp-tuning[]
320317
----
321318
endif::[]
322319

320+
ifndef::rosa-hcp-tuning[]
323321
To minimize node reboots, label the target nodes with a label the machine config pool's node selector will match, then create the Tuned CR above and finally create the custom machine config pool itself.
324-
322+
endif::rosa-hcp-tuning[]
325323
// $ oc label node <node> node-role.kubernetes.io/worker-custom=
326324
// $ oc create -f <tuned-cr-above>
327325
// $ oc create -f- <<EOF
@@ -342,7 +340,13 @@ To minimize node reboots, label the target nodes with a label the machine config
342340

343341
*Cloud provider-specific TuneD profiles*
344342

345-
With this functionality, all Cloud provider-specific nodes can conveniently be assigned a TuneD profile specifically tailored to a given Cloud provider on a {product-title} cluster. This can be accomplished without adding additional node labels or grouping nodes into machine config pools.
343+
With this functionality, all Cloud provider-specific nodes can conveniently be assigned a TuneD profile specifically tailored to a given Cloud provider on a {product-title} cluster. This can be accomplished without adding additional node labels or grouping nodes into
344+
ifndef::rosa-hcp-tuning[]
345+
machine config pools.
346+
endif::rosa-hcp-tuning[]
347+
ifdef::rosa-hcp-tuning[]
348+
machine pools.
349+
endif::rosa-hcp-tuning[]
346350

347351
This functionality takes advantage of `spec.providerID` node object values in the form of `<cloud-provider>://<cloud-provider-specific-id>` and writes the file `/var/lib/tuned/provider` with the value `<cloud-provider>` in NTO operand containers. The content of this file is then used by TuneD to load `provider-<cloud-provider>` profile if such profile exists.
348352

0 commit comments

Comments
 (0)