forked from openshift/openshift-docs
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request openshift#78971 from openshift-cherrypick-robot/ch…
…erry-pick-78787-to-enterprise-4.16 [enterprise-4.16] OSDOCS-6062: Steps to create a NodeFeatureDiscovery instance using the CLI for disconnected environment
- Loading branch information
Showing
4 changed files
with
213 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,167 @@ | ||
// Module included in the following assemblies: | ||
// | ||
// * hardware_enablement/psap-node-feature-discovery-operator.adoc | ||
|
||
:_mod-docs-content-type: PROCEDURE | ||
[id="creating-nfd-cr-cli-disconnected_{context}"] | ||
= Creating a NodeFeatureDiscovery CR by using the CLI in a disconnected environment | ||
|
||
As a cluster administrator, you can create a `NodeFeatureDiscovery` CR instance by using the {oc-first}. | ||
|
||
.Prerequisites | ||
|
||
* You have access to an {product-title} cluster | ||
* You installed the {oc-first}. | ||
* You logged in as a user with `cluster-admin` privileges. | ||
* You installed the the NFD Operator. | ||
* You have access to a mirror registry with the required images. | ||
* You installed the `skopeo` CLI tool. | ||
.Procedure | ||
|
||
. Determine the digest of the registry image: | ||
|
||
.. Run the following command: | ||
+ | ||
[source,terminal] | ||
---- | ||
$ skopeo inspect docker://registry.redhat.io/openshift4/ose-node-feature-discovery:<openshift_version> | ||
---- | ||
+ | ||
.Example command | ||
[source,terminal] | ||
---- | ||
$ skopeo inspect docker://registry.redhat.io/openshift4/ose-node-feature-discovery:v4.12 | ||
---- | ||
|
||
.. Inspect the output to identify the image digest: | ||
+ | ||
.Example output | ||
[source,terminal] | ||
---- | ||
{ | ||
... | ||
"Digest": "sha256:1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef", | ||
... | ||
} | ||
---- | ||
|
||
. Use the `skopeo` CLI tool to copy the image from `registry.redhat.io` to your mirror registry, by running the following command: | ||
+ | ||
[source,terminal] | ||
---- | ||
skopeo copy docker://registry.redhat.io/openshift4/ose-node-feature-discovery@<image_digest> docker://<mirror_registry>/openshift4/ose-node-feature-discovery@<image_digest> | ||
---- | ||
+ | ||
.Example command | ||
[source,terminal] | ||
---- | ||
skopeo copy docker://registry.redhat.io/openshift4/ose-node-feature-discovery@sha256:1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef docker://<your-mirror-registry>/openshift4/ose-node-feature-discovery@sha256:1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef | ||
---- | ||
|
||
. Create a `NodeFeatureDiscovery` CR: | ||
+ | ||
.Example `NodeFeatureDiscovery` CR | ||
[source,yaml,subs="attributes+"] | ||
---- | ||
apiVersion: nfd.openshift.io/v1 | ||
kind: NodeFeatureDiscovery | ||
metadata: | ||
name: nfd-instance | ||
spec: | ||
operand: | ||
image: <mirror_registry>/openshift4/ose-node-feature-discovery@<image_digest> | ||
imagePullPolicy: Always | ||
workerConfig: | ||
configData: | | ||
core: | ||
# labelWhiteList: | ||
# noPublish: false | ||
sleepInterval: 60s | ||
# sources: [all] | ||
# klog: | ||
# addDirHeader: false | ||
# alsologtostderr: false | ||
# logBacktraceAt: | ||
# logtostderr: true | ||
# skipHeaders: false | ||
# stderrthreshold: 2 | ||
# v: 0 | ||
# vmodule: | ||
## NOTE: the following options are not dynamically run-time configurable | ||
## and require a nfd-worker restart to take effect after being changed | ||
# logDir: | ||
# logFile: | ||
# logFileMaxSize: 1800 | ||
# skipLogHeaders: false | ||
sources: | ||
cpu: | ||
cpuid: | ||
# NOTE: whitelist has priority over blacklist | ||
attributeBlacklist: | ||
- "BMI1" | ||
- "BMI2" | ||
- "CLMUL" | ||
- "CMOV" | ||
- "CX16" | ||
- "ERMS" | ||
- "F16C" | ||
- "HTT" | ||
- "LZCNT" | ||
- "MMX" | ||
- "MMXEXT" | ||
- "NX" | ||
- "POPCNT" | ||
- "RDRAND" | ||
- "RDSEED" | ||
- "RDTSCP" | ||
- "SGX" | ||
- "SSE" | ||
- "SSE2" | ||
- "SSE3" | ||
- "SSE4.1" | ||
- "SSE4.2" | ||
- "SSSE3" | ||
attributeWhitelist: | ||
kernel: | ||
kconfigFile: "/path/to/kconfig" | ||
configOpts: | ||
- "NO_HZ" | ||
- "X86" | ||
- "DMI" | ||
pci: | ||
deviceClassWhitelist: | ||
- "0200" | ||
- "03" | ||
- "12" | ||
deviceLabelFields: | ||
- "class" | ||
customConfig: | ||
configData: | | ||
- name: "more.kernel.features" | ||
matchOn: | ||
- loadedKMod: ["example_kmod3"] | ||
---- | ||
|
||
. Create the `NodeFeatureDiscovery` CR by running the following command: | ||
+ | ||
[source,terminal] | ||
---- | ||
$ oc apply -f <filename> | ||
---- | ||
|
||
.Verification | ||
|
||
. Check the status of the `NodeFeatureDiscovery` CR by running the following command: | ||
+ | ||
[source,terminal] | ||
---- | ||
$ oc get nodefeaturediscovery nfd-instance -o yaml | ||
---- | ||
|
||
. Check that the pods are running without `ImagePullBackOff` errors by running the following command: | ||
+ | ||
[source,terminal] | ||
---- | ||
$ oc get pods -n <nfd_namespace> | ||
---- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// Module included in the following assemblies: | ||
// | ||
// * hardware_enablement/psap-node-feature-discovery-operator.adoc | ||
|
||
:_mod-docs-content-type: PROCEDURE | ||
[id="creating-nfd-cr-web-console_{context}"] | ||
= Creating a NodeFeatureDiscovery CR by using the web console | ||
|
||
As a cluster administrator, you can create a `NodeFeatureDiscovery` CR by using the {product-title} web console. | ||
|
||
.Prerequisites | ||
|
||
* You have access to an {product-title} cluster | ||
* You logged in as a user with `cluster-admin` privileges. | ||
* You installed the the NFD Operator. | ||
.Procedure | ||
|
||
. Navigate to the *Operators* -> *Installed Operators* page. | ||
. In the *Node Feature Discovery* section, under *Provided APIs*, click *Create instance*. | ||
. Edit the values of the `NodeFeatureDiscovery` CR. | ||
. Click *Create*. |