Configuring the SR-IOV Network Operator to use an unsupported NIC
The Single Root I/O Virtualization (SR-IOV) Network Operator defaults to a policy that restricts the configuration of network interface cards (NICs) to the list of supported devices only. Follow the described procedure to configure the SR-IOV Network Operator to use an unsupported NIC.
Warning:
Enabling an unsupported NICs is not officially supported, and any issues that arise from installing an unsupported NIC fall outside the Red Hat support contract.
Disabling the SR-IOV Network Operator admission controller webhook
To disable the admission controller webhook, complete the following procedure.
-
Install the OpenShift CLI (
oc). -
Log in as a user with
cluster-adminprivileges. -
You must have installed the SR-IOV Network Operator.
Procedure
-
Set the
enableOperatorWebhookfield tofalseto disable the feature:$ oc patch sriovoperatorconfig default --type=merge \ -n openshift-sriov-network-operator \ --patch '{ "spec": { "enableOperatorWebhook": false } }'You can alternatively apply the following YAML to update the Operator:
apiVersion: sriovnetwork.openshift.io/v1 kind: SriovOperatorConfig metadata: name: default namespace: openshift-sriov-network-operator spec: enableOperatorWebhook: false
Enabling SR-IOV Network Operator developer mode
Follow this procedure to enable SR-IOV Network Operator developer mode to allow the use of an unsupported NIC.
-
Install the OpenShift CLI (
oc). -
Log in as a user with
cluster-adminprivileges. -
You must have installed the SR-IOV Network Operator.
Procedure
-
Find the name of the Subscription CR for the SR-IOV Network Operator:
$ oc get subscription -n openshift-sriov-network-operator -
Update the subscription by patching its spec field by using the following command:
$ oc patch subscription sriov-network-operator -n openshift-sriov-network-operator --type=merge -p '{"spec": {"config": {"env": [{"name": "DEV_MODE", "value": "TRUE"}]}}}' -
Verify that the
sriov-network-operatorpods restarted by running the following command:$ oc -n openshift-sriov-network-operator get poExample output
NAME READY STATUS RESTARTS AGE network-resources-injector-6r49n 1/1 Running 0 22m network-resources-injector-skd5z 1/1 Running 0 22m network-resources-injector-wkr55 1/1 Running 0 22m sriov-network-config-daemon-cc24s 3/3 Running 0 22m sriov-network-config-daemon-hx5kd 3/3 Running 0 22m sriov-network-config-daemon-sb5xw 3/3 Running 0 22m sriov-network-operator-6dcf6f64f-4hf6d 1/1 Running 0 99sNOTE: The
sriov-network-operator-6dcf6f64f-4hf6dpod has restarted. -
Run the same command after a few minutes and verify the
sriov-network-config-daemonhas restarted:$ oc -n openshift-sriov-network-operator get poExample output
NAME READY STATUS RESTARTS AGE network-resources-injector-6r49n 1/1 Running 0 24m network-resources-injector-skd5z 1/1 Running 0 24m network-resources-injector-wkr55 1/1 Running 0 24m sriov-network-config-daemon-6txht 3/3 Running 0 15s sriov-network-config-daemon-lclsr 3/3 Running 0 16s sriov-network-config-daemon-qhwvk 3/3 Running 0 13s sriov-network-operator-6dcf6f64f-4hf6d 1/1 Running 0 3m28s -
Verify that the
sriov-network-config-daemonlogs reportdev mode enabledby running the following command:$ oc -n openshift-sriov-network-operator logs -f -c sriov-network-config-daemon sriov-network-config-daemon-bbdbwExample output
I0426 11:39:07.157483 35008 start.go:143] dev mode enabled I0426 11:39:07.157496 35008 start.go:146] starting node writer I0426 11:39:07.164103 35008 start.go:166] Running on platform: Baremetal I0426 11:39:07.167959 35008 writer.go:47] RunOnce()