Skip to main content
Kubernetes Dynamic Resource Allocation (DRA) is a new way of sharing host level resources into pods. These resources include GPU devices, high performance networking, and other hardware that a workload may need access to. DRA is enabled by default as a beta feature in Kubernetes 1.34 and can also be enabled in Kubernetes 1.33. DRA replaces device plugins for accessing resources from workloads.

Enable DRA in the cluster

Make sure the cluster has DRA enabled (Kubernetes 1.34+) or uses the following patch to enable the feature. This patch can be applied to all nodes in the cluster via talosctl or via Omni.
You should have at least one node in the cluster with NVIDIA hardware and configured via NVIDIA GPU (OSS drivers) or NVIDIA GPU (Proprietary drivers) guides.

1. Deploy the NVIDIA DRA plugin via Helm

Use helm to install the DRA plugin.
First we need to disable the device plugin component of GPU operator since we will be using the DRA plugin instead.
Note: the validation steps currently mention older versions of resource claims, follow the steps below to verify that the DRA plugin is running and managing the NVIDIA GPU resources.
Refer to the dra validation documentation.
Verify ResourceSlice objects
There should be a ResourceSlice object with the gpu.nvidia.com driver.

2. Deploy test workload

Create a pod that consumes the ResourceSlice via a ResourceClaimTemplate.
Verify that the pod is running and has access to the GPU resources.
The output is expected to show the same GPU UUID from both containers. Example:
clean up

Notes

DRA is currently a beta Kubernetes feature and it is likely that it will change in the future. Make sure you consult your hardware vendor’s documentation for up-to-date configuration and deployment guides.