Module 1: Fake GPU Cluster Setup
The fake-gpu-operator is a lightweight Kubernetes operator that simulates NVIDIA GPUs on CPU-only nodes. It provides a device plugin, metrics exporter, and nvidia-smi emulation — everything Kubernetes needs to schedule GPU workloads without real hardware.
The good news is that everything you learn in this module can be applied to a real GPU cluster. The commands and output that you see in this module are the same as you would see in a real GPU cluster. You’ll be able to inspect the GPU topology, deploy pods with fake GPUs, and use nvidia-smi inside fake GPU pods.
All of the workloads we deploy in this module do nothing but sleep — they are simply used to verify that the fake GPUs are working as expected. Even the nvidia-smi command used to verify that the fake GPUs are working is a fake nvidia-smi command injected into the pod by the fake-gpu-operator. Within a pod, there is no real nvidia GPU device or socket to connect to — it is all simulated.
In this module, you’ll explore how the operator works, inspect the simulated GPU topology, and verify that pods can request and consume fake GPU resources.
Learning objectives
By the end of this module, you’ll be able to:
-
Explain how the fake-gpu-operator simulates GPU resources
-
Inspect the GPU topology configured on your cluster
-
Deploy a pod that requests fake GPU resources
-
Use nvidia-smi inside a fake GPU pod
|
The exercises below use the NVIDIA GB200 NVL profile. If you are not using this profile, you will need to switch to it using the GPU Config Plugin. See the Quickstart module for more details. You may use other profiles if you wish - however you will need to adjust the commands accordingly. |
How does the fake-gpu-operator work?
The operator runs three main components on each labeled node:
| Component | Purpose |
|---|---|
Device Plugin |
Registers |
Status Updater |
Watches pod GPU allocations and reports utilization metrics to Prometheus |
nvidia-smi Injection |
Injects a fake |
Nodes are included in the simulation when labeled with run.ai/simulated-gpu-node-pool=<pool-name>. The operator reads topology configuration from the topology ConfigMap to determine GPU product, count, and memory per node pool.
| Use the GPU Config Plugin in the OpenShift Console (GPU Configuration > GPU Profiles) to switch between GPU profiles (A100, H100, H200, B200, GB200, L40S, T4) and configure MIG slice counts — no CLI required. |
Exercise 1: Inspect the GPU topology
|
Acting as:
|
-
View the node labels that identify fake GPU nodes:
oc get nodes -l nvidia.com/gpu.present=true --show-labels | grep -o 'nvidia[^ ]*'You should see a number of node labels including
nvidia.com/gpu.present=trueandrun.ai/simulated-gpu-node-pool=<pool-name>. -
Check the GPU capacity reported by the node:
oc get node -l nvidia.com/gpu.present=true \ -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{.metadata.labels.nvidia\.com/gpu\.product}{"\t"}gpu={.status.capacity.nvidia\.com/gpu}{"\n"}{end}'You should see the active GPU profile name and 8 full GPUs per node. MIG resources depend on the selected profile.
-
Inspect the fake-gpu-operator pods:
oc get pods -n gpu-operatorYou should see a number of pods including
device-plugin-<hash>,topology-server-<hash>,nvidia-dcgm-exporter-<hash>, andgpu-node-labeler-<hash>. -
Inspect the node allocatable resources:
oc get nodes -o jsonpath='{range .items[*]}{.metadata.name}{"\t"}{.status.allocatable}{"\n"}{end}' | while read name alloc; do echo "=== $name ==="; echo "$alloc" | jq .; doneYou should see cpu, memory, pods and
nvidia.com/gpuresource counts. If you seenvidia.com/mig-*resource counts, then you are running a MIG-capable profile.
| The MIG resources may be present but show "0" as the count. This is expected from any prior MIG profiles that have been set and are no longer in use. They only reset when the Kubelet is restarted on the node. |
Exercise 2: Deploy a pod with fake GPUs
|
Acting as:
|
-
Deploy a simple pod requesting one full GPU:
helm template gpu-deploy oci://quay.io/eformat/gpu-test-workloads -n user-user1 \ --set kind=Pod \ --set name=gpu-test \ --set replicas=1 \ --set gpuCount=1 \ --set gpuResourceType=nvidia.com/gpu \ --set reserved=false \ | oc -n user-user1 apply -f- -
Wait for the pod to start:
oc -n user-user1 wait pod/gpu-test --for=condition=Ready --timeout=60s -
Run nvidia-smi inside the pod:
oc -n user-user1 exec gpu-test -- nvidia-smiYou should see simulated NVIDIA GPU information for the active profile — product name, memory, and utilization — even though no real GPU exists.
|
Acting as:
|
-
Check the GPU resource usage on the node:
oc describe node -l nvidia.com/gpu.present=true | grep -A 15 "Allocated resources"You should see the GPU resource request and limits - usage - on each node.
Exercise 3: Test MIG partitions
|
Acting as:
|
-
Deploy a pod requesting a MIG 1g.23gb partition:
helm template gpu-deploy oci://quay.io/eformat/gpu-test-workloads -n user-user1 \ --set kind=Pod \ --set name=mig-test \ --set replicas=1 \ --set gpuCount=1 \ --set gpuResourceType=nvidia.com/mig-1g.23gb \ --set reserved=false \ | oc -n user-user1 apply -f- -
Wait for the pod to be ready:
oc -n user-user1 wait pod/mig-test --for=condition=Ready --timeout=60s -
and run nvidia-smi:
oc -n user-user1 exec mig-test -- nvidia-smiNotice the nvidia-smi output shows the MIG partition size
23552MiBrather than the full GPU memory. You should also be able to see the MIG workload in the Bookings dashboard.MIG resource types vary by GPU profile. If your cluster is running a non-MIG profile (L40S, T4), first switch to a MIG-capable profile using the GPU Config Plugin. See the Quickstart module for more details. -
Clean up both test pods:
oc -n user-user1 delete pod gpu-test mig-test
Module summary
What you accomplished:
-
Explored the fake-gpu-operator components and how they simulate GPU hardware
-
Inspected the GPU topology and verified the active GPU profile
-
Deployed pods requesting full GPUs and MIG partitions
-
Verified nvidia-smi emulation inside fake GPU pods
Key takeaways:
-
The fake-gpu-operator provides a complete GPU simulation layer — device plugin, metrics, and nvidia-smi
-
Pods request fake GPUs using the same resource names as real GPUs (
nvidia.com/gpu,nvidia.com/mig-*) -
MIG partitions allow multiple workloads to share a single GPU with isolated memory
-
The GPU Config Plugin lets you switch GPU profiles and MIG configurations from the console UI
-
This simulation approach lets you build and test GPU scheduling workflows without hardware cost
Next: Module 2 covers the GPU Booking App — a console plugin for reserving GPU time slots.

