Skip to main content

What is VMDirectPath IO and GPU passthru


One of the more interesting announcements that I believe flew under the radar was the joint VMware-NVIDIA initiative to bring virtual graphics processing unit technology (vGPU) to VMware’s vSphere and the VMware cloud on AWS so it’s really a good time to understand GPU passthrough concept.

Before we start, let’s get to know CPU vs GPU:
CPU is good at handling multiple tasks but a GPU can handle a few specific tasks very fast.
CPU is good for serial processing and has low latency while GPU is good at parallel processing and hence high throughput. In marvel comic terms, CPU is like Antman, GPU is a hulk – incredible hulk!  

okay, what is this thing "GPU passthrough" :
It is a technology that allows you to directly present an internal PCI GPU to a virtual machine. The device acts as if it were directly driven by the VM, and the VM detects the PCI device as if it were physically connected. VMware calls this operation as VMDirectPath I/O.

So why do we need such stuff:
To execute workloads with more computer power, simply for faster time to results.

Who uses all these crazy things:
Gamers - for smooth graphics,
Data scientists, Artificial Intelligence, Machine / Deep learning engineers to compute more data in a faster manner.

Interesting isn't it? and let’s see how do we enable it:

To Enable the Host for GPU Passthrough:

1. Select the Configuration tab on the host, and click Advanced Setting. (If the host has devices enabled for passthrough, these devices will be listed here.)
2. To configure passthrough for the GPU, click Configure Passthrough.
3. In the Mark Devices for Passthrough window, check the box that corresponds to the GPU adapter installed in the host.
4. Click OK. The GPU should now be listed now in the Window on the Advanced settings page.
Note: If the device has an orange arrow displayed on the icon, the host needs to be rebooted before passthrough will function. If the device icon is green, passthrough is enabled.

To Enable the Virtual Machine for GPU Passthrough:

1.Right-click the virtual machine and select Edit Settings
2. Add a new device by selecting PCI Device from the list, and click Next.
3. Select the GPU as the passthrough device to connect to the virtual machine from the drop-down list, and click Next.
4. Click Finish
5. Download and install the drivers according to the Virtual Machine's OS.
6. Reboot the virtual machine.

Quick links:

Comments

Popular posts from this blog

Error [403] The maximum number of sessions has been exceeded in the H5 client during login or logout

  Symptoms In virgo log, you see messages similar to: [2020-05-19T07:25:45.285Z] [ERROR] http-nio-5090-exec-130 72026859 142953 501051 com.vmware.vise.security.spring.DefaultAuthenticationProvider logout failed for sessionId 142953, clientId 501051 java.lang.IllegalStateException: The specified cardinality of 1..1 for osgi:reference implementing com.vmware.vcenter.apigw.api.ApiGatewaySessionManager in bundle com.vmware.h5ngc requires that exactly one OSGI service satisfies the filtering criteria but no such service was found.         at com.vmware.o6jia.context.ExternalServiceTargetSource.getTarget(ExternalServiceTargetSource.java:99)         at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:192)         at com.sun.proxy.$Proxy159.logout(Unknown Source)         at com.vmware.vise.security.spring.DefaultAuthenticationProvider.logoutInternal(DefaultAuthenticationProvider.java:548)         at c

Investigating virtual machine file locks on ESXi

      Details Adding an existing virtual machine disk (VMDK) to a virtual machine that is already powered on fails.                 Failed to add disk scsi0:1. Failed to power on scsi0:1   Powering on the virtual machine results in the power on task remaining at 95% indefinitely. Cannot power on the virtual machine after deploying it from a template. Powering on a virtual machine fails with an error: Unable to open Swap File Unable to access a file since it is locked Unable to access a file <filename> since it is locked Unable to access Virtual machine configuration In the /var/log/vmkernel log file, you see entries similar to: WARNING: World: VM xxxx: xxx: Failed to open swap file <path>: Lock was not free WARNING: World: VM xxxx: xxx: Failed to initialize swap file <path>   When opening a console to the virtual machine, you may receive the error: Error connecting to <path><virtual machin

"Performance data is currently not available for this entity" viewing the performance tab

  Symptoms While accessing the performance tab and navigating to Overview, you see: No data available   The data for Real time, but fails to retrieve it for past 1 day, week, month or year.  While selecting the advance parameter in performance tab, you see: Performance data is currently not available for this entity Cause This issue is caused by the vCenter Server database (Postgress) containing a stale/future time stamp reference for the ESXi host when the data was collected. For vCenter Servers using SQL, see  "Performance data is currently not available for this entity" error after updating rollup in vSphere Resolution Backup the vCenter database. For more info