Time-Slicing Cross-Pod VRAM Exhaustion
Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation. If a physical GPU with 24GB VRAM is time-sliced into 4 logical GPUs, Kubernetes allows scheduling 4 pods to it. If Pod A (the 'noisy neighbor') allocates 20GB of VRAM, Pods B, C, and D will instantly encounter CUDA OOM errors because the physical memory pool is exhausted, despite Kubernetes acting as if they each possess dedicated resources.
Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation.
- Root cause
- Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation. If a physical GPU with 24GB VRAM is time-sliced into 4 logical GPUs, Kubernetes allows scheduling 4 pods to it. If Pod A (the 'noisy neighbor') allocates 20GB of VRAM, Pods B, C, and D will instantly encounter CUDA OOM errors because the physical memory pool is exhausted, despite Kubernetes acting as if they each possess dedicated resources.
- Recommended fix
- Enforce Application-Level Memory Limits For PyTorch: torch.cuda.set_per_process_memory_fraction(0.25) / For TF: set memory_growth or virtual_device memory limit. Since the infrastructure cannot isolate the memory, the applications must be configured to artificially restrict their own VRAM allocation, preventing them from stepping on each other.
- How Denpex helps
- Denpex matches Time-Slicing Cross-Pod VRAM Exhaustion across every rank in a distributed run and reports which rank failed first, so you act on the initiating node instead of the loudest one.
What this failure is
Time-Slicing Cross-Pod VRAM Exhaustion is a Memory failure seen during ML training runs. Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation. If a physical GPU with 24GB VRAM is time-sliced into 4 logical GPUs, Kubernetes allows scheduling 4 pods to it. If Pod A (the 'noisy neighbor') allocates 20GB of VRAM, Pods B, C, and D will instantly encounter CUDA OOM errors because the physical memory pool is exhausted, despite Kubernetes acting as if they each possess dedicated resources. Common tags: Isolation.
Is this what broke your run? Paste your log.
You're reading about Time-Slicing Cross-Pod VRAM Exhaustion. Paste your own crash log or traceback below and get the real root cause for YOUR run, not this generic entry. No account, no card. Logs are masked at ingress and never saved to account history.
Want 14 days on the Scale plan?
Request an evaluation code. A verified workplace organization activates up to 50 diagnoses a day, alerts, history, and follow-up questions. No credit card or automatic subscription.
Why it happens (the mechanism)
The user requested 'nvidia.com/gpu: 1' in their pod spec, which conventionally implies exclusive access to a GPU. The scheduling succeeds, so the user assumes they have sufficient resources. The failure appears non-deterministic because it depends entirely on the concurrent memory usage of other tenants on the same physical card.
What you'll observe
- CUDA_ERROR_OUT_OF_MEMORY during context initialization
- Failed to allocate memory for the GPU context
Common symptoms and what they mean
| Symptom | Why it happens |
|---|---|
| A newly scheduled pod immediately crashes with an OOM error upon startup. | Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation. If a physical GPU with 24GB VRAM is time-sliced into 4 logical GPUs, Kubernetes allows scheduling 4 pods to it. If Pod A (the 'noisy neighbor') allocates 20GB of VRAM, Pods B, C, and D will instantly encounter CUDA OOM errors because the physical memory pool is exhausted, despite Kubernetes acting as if they each possess dedicated resources. |
| Existing, previously stable pods suddenly crash with CUDA OOMs at random intervals. | Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation. If a physical GPU with 24GB VRAM is time-sliced into 4 logical GPUs, Kubernetes allows scheduling 4 pods to it. If Pod A (the 'noisy neighbor') allocates 20GB of VRAM, Pods B, C, and D will instantly encounter CUDA OOM errors because the physical memory pool is exhausted, despite Kubernetes acting as if they each possess dedicated resources. |
| Occurs exclusively on nodes where GPU time-slicing (e.g., replicas: 4) is enabled. | Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation. If a physical GPU with 24GB VRAM is time-sliced into 4 logical GPUs, Kubernetes allows scheduling 4 pods to it. If Pod A (the 'noisy neighbor') allocates 20GB of VRAM, Pods B, C, and D will instantly encounter CUDA OOM errors because the physical memory pool is exhausted, despite Kubernetes acting as if they each possess dedicated resources. |
Which systems are affected
- NVIDIA GPU Operator
- Time-Slicing Device Plugin
How to confirm this is the problem
Use this checklist to test the hypothesis against a small reproduction. No single line proves the root cause, so preserve the preceding events and compare one variable at a time.
- ✓Check node configuration to confirm time-slicing is active: kubectl get node -o yaml | grep 'nvidia.com/gpu.replicas'
- ✓Run 'nvidia-smi' on the node to view the aggregated memory usage of all processes sharing the GPU.
The fix and the prevention pattern
The root cause is on this page and stays free. A free account adds the exact remediation steps, saved history, and the fix on every entry in the encyclopedia.
Sign up free. Unlock the full analysisNo credit card. Daily allowance follows verified trust tier. Instant access.
Diagnose this failure in VS Code
Select the traceback or open the failed terminal, then run Denpex locally to see the initiating rank, collateral failures, exact fix, and verification command without uploading the log.
Install the free VS Code extensionRoot cause
- Kubernetes GPU time-slicing multiplexes compute execution time, but it provides absolutely zero hardware-level memory isolation. If a physical GPU with 24GB VRAM is time-sliced into 4 logical GPUs, Kubernetes allows scheduling 4 pods to it. If Pod A (the 'noisy neighbor') allocates 20GB of VRAM, Pods B, C, and D will instantly encounter CUDA OOM errors because the physical memory pool is exhausted, despite Kubernetes acting as if they each possess dedicated resources.
The fix and how to prevent it
Evaluate Denpex on your own logs
Request a Scale evaluation code. A verified workplace organization activates 14 days with up to 50 diagnoses a day. Every account keeps its current diagnosis allowance and gets a verification path. No card or automatic subscription.
Don't just read the fix, diagnose your run
The encyclopedia tells you what went wrong. Denpex tells you what went wrong in YOUR training run. With your logs, your config, and your stack.