Your virtual machines can access a virtual GPU (vGPU) hardware. Assigning a vGPU to your virtual machine allows you do the following:

  • Access a fraction of the underlying hardware’s GPU to achieve high performance benefits in your virtual machine.

  • Streamline resource-intensive I/O operations.

vGPU passthrough can only be assigned to devices that are connected to clusters running in a bare metal environment.

Assigning vGPU passthrough devices to a virtual machine

Use the OKD web console to assign vGPU passthrough devices to your virtual machine.

  • The virtual machine must be stopped.

  1. In the OKD web console, click Virtualization → VirtualMachines from the side menu.

  2. Select the virtual machine to which you want to assign the device.

  3. On the Details tab, click GPU devices.

    If you add a vGPU device as a host device, you cannot access the device with the VNC console.

  4. Click Add GPU device, enter the Name and select the device from the Device name list.

  5. Click Save.

  6. Click the YAML tab to verify that the new devices have been added to your cluster configuration in the hostDevices section.

You can add hardware devices to virtual machines created from customized templates or a YAML file. You cannot add devices to pre-supplied boot source templates for specific operating systems, such as Windows 10 or RHEL 7.

To display resources that are connected to your cluster, click ComputeHardware Devices from the side menu.