1
0
mirror of https://github.com/openshift/openshift-docs.git synced 2026-02-05 12:46:18 +01:00
Files
openshift-docs/modules/virt-adding-kernel-arguments-enable-iommu.adoc
2023-10-30 10:13:25 -04:00

58 lines
1.6 KiB
Plaintext

// Module included in the following assemblies:
//
// * virt/virtual_machines/advanced_vm_management/configuring-pci-passthrough.adoc
// * virt/virtual_machines/advanced_vm_management/virt-configuring-virtual-gpus.adoc
:_mod-docs-content-type: PROCEDURE
[id="virt-adding-kernel-arguments-enable-IOMMU_{context}"]
= Adding kernel arguments to enable the IOMMU driver
To enable the IOMMU driver in the kernel, create the `MachineConfig` object and add the kernel arguments.
.Prerequisites
* You have cluster administrator permissions.
* Your CPU hardware is Intel or AMD.
* You enabled Intel Virtualization Technology for Directed I/O extensions or AMD IOMMU in the BIOS.
.Procedure
. Create a `MachineConfig` object that identifies the kernel argument. The following example shows a kernel argument for an Intel CPU.
+
[source,yaml]
----
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfig
metadata:
labels:
machineconfiguration.openshift.io/role: worker <1>
name: 100-worker-iommu <2>
spec:
config:
ignition:
version: 3.2.0
kernelArguments:
- intel_iommu=on <3>
# ...
----
<1> Applies the new kernel argument only to worker nodes.
<2> The `name` indicates the ranking of this kernel argument (100) among the machine configs and its purpose. If you have an AMD CPU, specify the kernel argument as `amd_iommu=on`.
<3> Identifies the kernel argument as `intel_iommu` for an Intel CPU.
. Create the new `MachineConfig` object:
+
[source,terminal]
----
$ oc create -f 100-worker-kernel-arg-iommu.yaml
----
.Verification
* Verify that the new `MachineConfig` object was added.
+
[source,terminal]
----
$ oc get MachineConfig
----