Kubernetes for AI/ML: GPU Scheduling with NVIDIA GPU Operator

We design and deploy artificial intelligence systems: from prototype to production-ready solutions. Our team combines expertise in machine learning, data engineering and MLOps to make AI work not in the lab, but in real business.
Showing 1 of 1All 1566 services
Kubernetes for AI/ML: GPU Scheduling with NVIDIA GPU Operator
Complex
~3-5 days
Frequently Asked Questions

AI Development Areas

AI Solution Development Stages

Latest works

  • image_website-b2b-advance_0.webp
    B2B ADVANCE company website development
    1319
  • image_web-applications_feedme_466_0.webp
    Development of a web application for FEEDME
    1226
  • image_websites_belfingroup_462_0.webp
    Website development for BELFINGROUP
    927
  • image_ecommerce_furnoro_435_0.webp
    Development of an online store for the company FURNORO
    1161
  • image_logo-advance_0.webp
    B2B Advance company logo design
    622
  • image_crm_enviok_479_0.webp
    Development of a web application for Enviok
    897

In a production cluster with 8× NVIDIA A100, we faced GPU utilization of only 40% due to lack of MIG and improper scheduling. After implementing the NVIDIA GPU Operator and gang scheduling, utilization rose to 92%, and idle time dropped by 55%. Our team has 5+ years of experience configuring GPU clusters for AI/ML and has delivered over 20 projects. Without proper GPU scheduling, you risk losing up to 60% of resources — direct losses. Our experience shows that correct Kubernetes configuration for AI/ML workloads guarantees GPU utilization above 90% and reduces GPU infrastructure costs by 30–50%. Have your cluster audited — we'll identify bottlenecks and suggest optimization.

How the NVIDIA GPU Operator Simplifies GPU Management

The operator automatically deploys NVIDIA drivers, container toolkit, and device plugin — all via Custom Resources. Manual configuration on each node is eliminated. The result is a cluster with GPU support ready in one Helm release, 3 times faster than manual setup. The NVIDIA GPU Operator documentation confirms this.

Installation command
helm repo add nvidia https://helm.ngc.nvidia.com/nvidia
helm repo update
helm install gpu-operator nvidia/gpu-operator \
  --namespace gpu-operator --create-namespace \
  --set driver.enabled=true --set driver.version="545.23.06" \
  --set toolkit.enabled=true --set devicePlugin.enabled=true \
  --set dcgmExporter.enabled=true --set gfd.enabled=true
kubectl get pods -n gpu-operator
kubectl get nodes -o custom-columns='NAME:.metadata.name,GPU:.status.capacity.nvidia\.com/gpu'

Why Proper GPU Scheduling Matters

Typical issues: a job cannot start because whole GPUs are unavailable, even though free MIG slices exist; or one task blocks the entire node. The solution is a combination of MIG, gang scheduling, and priorities.

Mechanism When to use Typical utilization
Whole GPUs Models requiring >24 GB memory 70–85%
MIG (1g.10gb) Small batch jobs, inference 80–90%
Gang scheduling Distributed training (PyTorch DDP) 85–95%

The standard Kubernetes scheduler does not support gang scheduling, causing deadlock in distributed training. Volcano and Kueue solve this: Volcano is mature with fair sharing; Kueue is a native API. For large clusters, Volcano delivers 85–95% utilization versus 60–75% for the standard scheduler — a 30% improvement.

How to Avoid Deadlock in Distributed Training

Gang scheduling with Volcano ensures all pods of a distributed task start simultaneously:

apiVersion: batch.volcano.sh/v1alpha1
kind: Job
metadata:
  name: distributed-training
spec:
  minAvailable: 4
  schedulerName: volcano
  tasks:
    - replicas: 1
      name: master
      template:
        spec:
          containers:
            - name: master
              image: your-registry/pytorch-trainer:v1
              resources:
                limits:
                  nvidia.com/gpu: 8
    - replicas: 3
      name: worker
      template:
        spec:
          containers:
            - name: worker
              image: your-registry/pytorch-trainer:v1
              resources:
                limits:
                  nvidia.com/gpu: 8

Why Use MIG?

MIG (Multi-Instance GPU) on A100/H100 splits a GPU into up to 7 instances. Switching to MIG increases task placement density and reduces GPU costs. Request in a pod spec:

resources:
  limits:
    nvidia.com/mig-1g.10gb: 1

How to Set Priorities for ML Tasks

For production inference, set a PriorityClass with high priority (1000); for batch training, low priority (100) with PreemptLowerPriority. Critical services always get GPUs first; training runs on leftover resources.

What's Included in Cluster Setup

  • Deployment of the NVIDIA GPU Operator with drivers and DCGM Exporter.
  • PriorityClass for inference prioritization.
  • Node labels for grouping GPU types (A100, V100, A10G).
  • Gang scheduling (Volcano or Kueue).
  • Cluster Autoscaler for dynamic GPU node scaling.
  • Grafana dashboard with utilization, temperature, and NVLink metrics.
  • Documentation and team training (optional).

How We Do It: Phases

  1. Infrastructure audit — measure p99 latency, utilization, identify bottlenecks.
  2. Design — choose a scheduler, define resource profiles and MIG configurations.
  3. Implementation — Helm releases, monitoring setup, tests with synthetic loads.
  4. Testing — verify FLOPS, low-priority job preemption, gang scheduling correctness.
  5. Deployment and support — hand over documentation, activate monitoring, provide SLA.

Common mistakes when configuring a GPU cluster:

  • Missing node labels — pods don't know which GPU type is on the node. Solution: kubectl label node gpu-node-1 nvidia.com/gpu.product=A100-SXM4-80GB.
  • Unconfigured Cluster Autoscaler — the cluster doesn't grow under peak load. Specify min/max GPU nodes.
  • No monitoring — performance degradation goes unnoticed. DCGM Exporter + Grafana provide full visibility.

Comparison of GPU Scheduling Approaches

Approach Advantages Disadvantages
Standard K8s scheduler Simplicity No gang scheduling, low utilization
Volcano Gang scheduling, fair sharing Additional component
Kueue Native API, easy integration Limited policies

Proper GPU scheduling in Kubernetes is key to efficient AI/ML workloads. We guarantee GPU utilization above 85% and stable operation even under peak load. Contact us for a cluster audit — we'll assess current utilization and suggest optimization. Get a consultation and a detailed implementation plan.