VMWare - Redhat 9 Install NVidia Pass through and Container Setup
Installing an NVIDIA driver in a Red Hat 9 virtual machine (VM) with GPU passthrough involves several steps, including configuring both the VMware ESXi host and the RHEL guest OS. GPU passthrough dedicates the entire physical GPU to a single VM, bypassing the hypervisor.
Reviewed 7October Oct2026 2026. Current releases:against RHEL 9.8 (May 2026) and NVIDIA data center driver branch 615. This VM'sguide GPUuses isan aNVIDIA Tesla M10 (Maxwell). NVIDIA driver branch R580 is the last branch that supports Maxwell, Pascal and Volta.Volta GPUs. It is a Long Term Support Branch with end of life in June 2028, so thisa VMMaxwell card must stay on the 580 proprietary DKMS stream. Newer branches drop Maxwell, and from branch 615 NVIDIA ships only the open kernel modules, which need Turing or newer.
Step 1: Enable GPU passthrough on the ESXi host
- In the host BIOS/UEFI, make sure Intel VT-d (AMD: IOMMU) is enabled and PCI mapping above 4 GB is allowed.
- In the vSphere Client select the host, then Configure > Hardware > PCI Devices and open All PCI Devices. (ESXi Host Client: Manage > Hardware > PCI Devices.)
FindSelectyourthe NVIDIA GPUdevice in the listand click Toggle Passthrough.- If the device shows an orange icon, put the host
mustinbe rebooted (maintenance modefirst)and reboot it before using thedevice can be used.device. The passthrough status should then show as Enabled/Active.
Step 2: Configure the RHEL 9 virtual machine
- Power off the virtual machine. This is
criticalrequired before assigning PCIdevicesdevices.. - Edit the settings of
yourthe RHEL 9 VM in the vSphere Client. - Under VM Options > Boot Options set Firmware to EFI
., because GPU passthrough VMs will not boot correctly on legacy BIOS. Make sure Secure Boot is disabled;seeStep 4forexplainsthe reason.why. - Under Virtual Hardware,
Clickclick Add New Deviceand, choose PCI Device.From the dropdown menu,and select the NVIDIA GPU youjust configuredenabled for passthrough.
- Under Memory, reserve all guest memory (All locked). A passthrough device needs the full memory reservation.
NavigateGo to VM Options > Advancedand, click Edit Configuration.Addandoraddmodifythesetheparameters:following key-value pairs:pciPassthru.use64bitMMIO = TRUEpciPassthru.64bitMMIOSizeGB = 64: the value depends onyour card'sGPU memory. Broadcom's rule is to add up the framebuffer memory of every GPU in the VM. If the total is a power of 2, use the next power of 2. If it falls between two powers of 2, round up twice. One Tesla M10 GPU (8 GB) needs at least 16; 64 also works.hypervisor.cpuid.v0 = FALSE:keptusedfromin theoriginaltestedworking build.setup. It is not part of Broadcom's GPU passthrough KBs.
- Save the VM settings and power on the VM.
Step 3: Prepare the OS
VMware tools: Broadcom recommends the open-vm-tools package shipped by Red Hat.
sudo dnf install -y open-vm-tools
Enable CodeReady Builder and EPEL: the NVIDIA driver RPMs depend on packages that only exist in EPEL (for example DKMS).
sudo subscription-manager repos --enable=codeready-builder-for-rhel-9-x86_64-rpms
sudo dnf install https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
Install build dependencies: youDKMS needneeds the kernel headers and development packages for the DKMS build.packages. On RHEL 9 NVIDIA uses kernel-devel-matched, which also pullsinstalls the matching devel package for future kernel updates so DKMS can rebuild the module.
sudo dnf groupinstall "Development Tools"
sudo dnf install kernel-devel-matched kernel-headers
DisablingDisable the Nouveau driver:driver (optional): the open-source Nouveau driver can conflict with the NVIDIA driver. The NVIDIA RPMs now disable nouveau automatically during install (nvidia-boot-update),. so this step is optional. If youTo do it by hand, note the option is modeset (the old page had a typo, modset).hand:
sudo bash -c "echo blacklist nouveau > /etc/modprobe.d/blacklist-nvidia-nouveau.conf"
sudo bash -c "echo options nouveau modeset=0 >> /etc/modprobe.d/blacklist-nvidia-nouveau.conf"
Regenerate the initial RAM disk image and reboot
sudo dracut --force
sudo reboot
Step 4: Install the NVIDIA driver (Tesla M10 = 580 branch, proprietary DKMS)
DoFor Maxwell GPUs such as the Tesla M10, do not use nvidia-driver:latest-dkms, nvidia-driver:open-dkms or nvidia-open on this VM.. In NVIDIA's RHEL 9 reporepository latest-dkms now resolves to the 610 branch, which no longer supports Maxwell. The open kernel modules only support Turing and newer GPUs.
Add the repository: NVIDIA's network repository for RHEL 99.
sudo dnf config-manager --add-repo https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/cuda-rhel9.repo
sudo dnf clean expire-cache
Install the driver: use the dnf module stream locked to the 580 branch with proprietary DKMS modules. Its default profile installs the full driver plus kmod-nvidia-latest-dkms.
sudo dnf module install nvidia-driver:580-dkms
Later updates stay on the 580 branch with a normal sudo dnf update.
Secure Boot: the DKMS-built proprietary modules are not signed by Red Hat. Red Hat-signed precompiled NVIDIA modules exist only for the open kernel modules (RHEL 10), which theMaxwell M10GPUs cannot use. Keep Secure Boot off for this VM.
See Nvidia for more references here (background on module streams: NVIDIA blog)off.
Reboot the VMVM:
sudo reboot
Step 5: Verify the installation
After the VM reboots, open a terminal and run the nvidia-smi. command.
nvidia-smiIf the installationinstall wasworked, successful,it thisshows command will display information about your NVIDIAthe GPU, confirmingwhich confirms that it is being used by the RHEL guest and that passthrough is workingusing correctly.it Youthrough should see something like this:passthrough:
|
Step 6: SetupSet forup Containercontainers
Add NVIDIA's container toolkit repository (NVIDIA's documented repo; the CUDA reporepository above also carries the same packages):
curl -s -L https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo | \
sudo tee /etc/yum.repos.d/nvidia-container-toolkit.repo
Install the NVidiaNVIDIA containerContainer toolkit packages:Toolkit:
sudo dnf install -y nvidia-container-toolkit
Use only this repo. The oldolder nvidia-docker2 / nvidia-docker and nvidia-container-runtime reposrepositories and packages are not part of NVIDIA's current install guide.guide; use the repository above.
Docker
Once the NVidia container toolkit is installed, configureConfigure Docker to use the NVIDIA runtime and restart it:
sudo nvidia-ctk runtime configure --runtime=docker
sudo systemctl restart docker
EnsureTest that everything is setup correctly for the docker system:it:
sudo$ docker run --rm --runtime=nvidia --gpus all ubuntu nvidia-smi
You should see something like this
+-----------------------------------------------------------------------------------------+ |
Podman (CDI)
For Podman, RHEL's built-in engine):container use CDI
For Podmanengine, NVIDIA recommends CDI instead of nvidia-ctk runtime configure. Since toolkit v1.18 the nvidia-cdi-refresh service generates the CDI spec is generated automatically at /var/run/cdi/nvidia.yaml by the nvidia-cdi-refresh service.. It runs when the toolkit or driver is installed or upgraded and at boot. List the devices:
nvidia-ctk cdi list
Regenerate the spec if needed (for example after removing a driver):
sudo systemctl restart nvidia-cdi-refresh.service
# or manually
sudo nvidia-ctk cdi generate --output=/var/run/cdi/nvidia.yaml
Test:Test it:
podman run --rm --security-opt=label=disable --device=nvidia.com/gpu=all ubuntu nvidia-smi
NoteTroubleshooting: Worthy:driver missing after a kernel update
With kernel-devel-matched installed, DKMS rebuilds the module automatically after kernel updates. If nvidia-smi stops working after a kernel update, check:
dkms statusThis showscheck which kernels the module is built for.for:
dkms status
Example fromoutput thiswhere VMthe (builtmodule is only built for an older el9_4 kernel):kernel:
|
Make sure kernel-devel for the running kernel is installed, then build itthe module for the current kernelkernel. (useUse the version shown by dkms status):
sudo dkms install nvidia/580.95.05
Container
References
- NVIDIA Container Toolkit install guide
,and CDI support - Ollama Docker image
Configuration(container configuration) - NVIDIA blog: driver module streams on RHEL (background)
Sources (checked 7 OctOctober 2026)
- Red Hat: RHEL release dates (RHEL 9.8 GA 2026-05-19)
- NVIDIA Driver Installation Guide: RHEL, Recent Updates (proprietary modules removed), Advanced Options (nvidia-boot-update)
- NVIDIA supported drivers and NVIDIA blog: R580 last branch for Maxwell/Pascal/Volta
- NVIDIA Container Toolkit
install guide,CDI support,sample workload - Broadcom KB 334594 (EFI + 64-bit MMIO sizing), KB 312208 (DirectPath I/O requirements), KB 309986 (Toggle Passthrough), KB 313456 (open-vm-tools)
Older instructions (before Oct 2026) - do not use on the M10 VM
Kept for reference only. latest-dkms now installs a driver branch that does not support the Tesla M10.
sudo dnf install kernel-devel-$(uname -r) kernel-headers-$(uname -r)
sudo dnf module install nvidia-driver:latest-dkms