Kubernetes v1.38.0-rc.0 Hands-On Labs: Pod-Level In-Place Resize, DRA Partitionable & Binding Gates, kuberc v1, and Live Upgrade¶
Test Date: 2026-12-05 | Cluster Version: Upgraded in-place from
v1.37.2tov1.38.0-rc.0(built with Go1.27.4,etcd 3.7.3-0,CoreDNS v1.15.0,pause 3.10.2) | Environment: 3-nodelinux/amd64cluster (1 control plane + 2 workers,cgroup v2unified hierarchy,containerd://2.4.2, Cilium data plane withoutkube-proxy) | Verification Standard: Every manifest, command, Linuxcgroup v2readout, scheduler event, and latency number below is measured live onv1.38.0-rc.0.
Kubernetes v1.38.0-rc.0 shipped on December 4, 2026 (ahead of the planned December 16 GA release). Rather than laying groundwork alone, v1.38 graduates four headline capabilities directly impacting AI inference, sidecar efficiency, and GPU/accelerator orchestration to Stable / GA, alongside KEP-4033 (CRI cgroupDriver discovery), KEP-3104 (kuberc v1), and KEP-4006 (WebSockets transition).
We upgraded a live 3-node cluster in-place from v1.37.2 to v1.38.0-rc.0 with zero workload evictions, then ran 5 end-to-end hands-on labs covering every headline feature and real upgrade pitfall with reproducible manifests, measured numbers, and architecture diagrams.
1. Executive Summary of Verified Results¶
| Lab Module | KEP & 1.38 Stage | Live Cluster Measurement |
|---|---|---|
| Lab 1 · Pod-Level Resources | KEP-2837 (GA) |
On the same 1-core / 512Mi quota, app and sidecar share a Pod-level pool with Guaranteed QoS; 600 MB SHA-256 burst latency drops from 5,592 ms (static split) to 2,835 ms (1.97×) |
| Lab 2 · Pod-Level In-Place Resize | KEP-5419 (GA) |
Live --subresource=resize updates (500m → 1000m → 2000m) converge in host cgroup v2 within 0.84–1.32 s with restartCount=0 and unchanged containerID; 2-worker throughput scales linearly from 105.2 to 428.3 MB/s (4.07×) |
| Lab 3A · DRA Partitionable Devices | KEP-4815 (GA) |
One 141Gi / 100 CU physical GPU sharedCounters packs mig-a (227 ms) + mig-b (249 ms) concurrently, cleanly blocks overlapping whole-GPU gpu0-full (Unschedulable), and backfills gpu0-full in 222 ms upon release |
| Lab 3B · DRA Binding Conditions | KEP-5007 (GA) |
Devices with bindingConditions: [FabricReady] reserve the claim while holding the Pod at BindingConditionsPending; patching FabricReady=True binds in 1,923 ms; patching FabricFailed=True aborts PreBind cleanly so the Pod never lands on a broken fabric |
Lab 4 · kuberc v1 & WebSockets |
KEP-3104 / KEP-4006 (GA) |
kubectl.config.k8s.io/v1 aliases work and reject the dropped legacy name allowlist field; even with KUBECTL_REMOTE_COMMAND_WEBSOCKETS=false, exec negotiates 101 Switching Protocols (v5.channel.k8s.io) |
Lab 5 · CRI cgroupDriver Discovery |
KEP-4033 (1.38 Tightening) |
After removing static cgroupDriver: systemd from cm/kubelet-config and node config while preserving custom containerRuntimeEndpoint, all 3 nodes auto-discover systemd from containerd 2.4.2 |
2. Lab 1: Pod-Level Resources (KEP-2837 GA) & cgroup v2 Proof¶
Historically, multi-container Pods (application + logging/proxy sidecars, or LLM serving + model-loader sidecars) had to partition CPU and memory statically across each container—forcing teams to over-provision every container to avoid OOMKills or CPU throttling.
Kubernetes v1.38 graduates PodLevelResources (KEP-2837) along with PodLevelResourcesFixDefaulting and PodLevelResourcesFixKubeletQOSClass to GA, letting sibling containers dynamically share a unified spec.resources budget defined at the Pod level.
2.1 Controlled Comparison (Identical 1-Core / 512Mi Quota)¶
We deployed two Pods on the same worker node reserving the exact same cluster quota (cpu: 1, memory: 512Mi):
- pod-level-shared: Pod-level requests == limits = 1 / 512Mi; app and sidecar only specify baseline requests: 200m / 128Mi with no container-level hard limits.
- container-level-split: Traditional static split giving app and sidecar 500m / 256Mi each.
apiVersion: v1
kind: Pod
metadata:
name: pod-level-shared
namespace: k8s138-lab
spec:
restartPolicy: Never
resources:
requests:
cpu: "1"
memory: "512Mi"
limits:
cpu: "1"
memory: "512Mi"
containers:
- name: app
image: docker.io/library/ubuntu:24.04
command: ["bash", "-lc", "sleep 3600"]
resources:
requests:
cpu: "200m"
memory: "128Mi"
- name: sidecar
image: docker.io/library/ubuntu:24.04
command: ["bash", "-lc", "sleep 3600"]
resources:
requests:
cpu: "200m"
memory: "128Mi"
2.2 Host cgroup v2 Hierarchy Verification & Burst Benchmark¶
Inspecting /sys/fs/cgroup/kubepods.slice/ directly on the worker node reveals exactly why Pod-level pooling works:
# Verified on worker node (Linux cgroup v2 unified hierarchy)
=== pod-level-shared (status.qosClass = Guaranteed) ===
pod cgroup cpu.max: 100000 100000 # 1.0 core cap shared by all containers
pod cgroup memory.max: 536870912 # 512 MiB cap shared by all containers
container app cpu.max: 100000 100000 # can burst up to full 1.0 core when sidecar is idle
container sidecar max: 100000 100000
=== container-level-split (status.qosClass = Guaranteed) ===
pod cgroup cpu.max: 100000 100000
pod cgroup memory.max: 536870912
container app cpu.max: 50000 100000 # hard-throttled at 0.5 core even when sidecar is idle
container sidecar max: 50000 100000
Running 3 rounds of a 600 MB sha256sum CPU burst inside app while sidecar sits idle:
- container-level-split: 5,776 / 5,592 / 5,546 ms (median 5,592 ms);
- pod-level-shared: 2,781 / 2,835 / 2,840 ms (median 2,835 ms)—1.97× faster burst completion under the exact same cluster reservation and Guaranteed QoS class.
3. Lab 2: Pod-Level In-Place Vertical Scaling (KEP-5419 GA)¶
Paired with KEP-2837, v1.38 promotes InPlacePodLevelResourcesVerticalScaling (KEP-5419) to GA: operators can patch Pod-level CPU and memory budgets live via --subresource=resize without restarting or recreating any container.
For AI inference and data workloads, this solves the classic startup-spike dilemma—for instance, giving an inference Pod generous CPU and host memory while loading weights or CPU-pinned PLE tables, then shrinking in-place once steady-state serving begins without dropping active connections.
3.1 Live /resize Command & 6-Step Measured Results¶
We executed 6 live Pod-level resizes on the running pod-level-shared Pod (both single-worker 600 MB and 2-worker parallel 800 MB benchmarks), polling /sys/fs/cgroup/cpu.max and memory.max inside the container while confirming containerID and restartCount:
# Resize Pod-level resources live via the /resize subresource (zero restart)
kubectl -n k8s138-lab patch pod pod-level-shared \
--subresource=resize --type=merge \
-p '{"spec":{"resources":{"requests":{"cpu":"2","memory":"1Gi"},"limits":{"cpu":"2","memory":"1Gi"}}}}'
| Workload Mode | Target Pod Resources | cgroup v2 Convergence |
Container cpu.max / memory.max |
3-Round Median | Measured Throughput (Scaling) | restartCount / containerID |
|---|---|---|---|---|---|---|
| 1-Worker 600 MB | 500m / 256Mi |
1,119.7 ms |
50000 100000 / 256 MiB |
5,758 ms |
104.2 MB/s (1.00×) |
0 / Unchanged |
| 1-Worker 600 MB | 1000m / 512Mi |
1,206.7 ms |
100000 100000 / 512 MiB |
2,855 ms |
210.2 MB/s (2.02×) |
0 / Unchanged |
| 1-Worker 600 MB | 2000m / 1Gi |
1,315.6 ms |
200000 100000 / 1 GiB |
2,587 ms |
231.9 MB/s (1-core bound) |
0 / Unchanged |
| 2-Worker 800 MB | 500m / 256Mi |
892.8 ms |
50000 100000 / 256 MiB |
7,606 ms |
105.2 MB/s (1.00×) |
0 / Unchanged |
| 2-Worker 800 MB | 1000m / 512Mi |
858.1 ms |
100000 100000 / 512 MiB |
3,704 ms |
216.0 MB/s (2.05×) |
0 / Unchanged |
| 2-Worker 800 MB | 2000m / 1Gi |
840.5 ms |
200000 100000 / 1 GiB |
1,868 ms |
428.3 MB/s (4.07×) |
0 / Unchanged |

Across all 6 live /resize steps, cgroup v2 limits converged in 0.84–1.32s with restartCount=0 and identical containerID, delivering textbook 1.00× → 2.05× → 4.07× linear compute scaling on the exact same running process.
4. Lab 3: DRA Partitionable Devices (KEP-4815 GA) & Binding Conditions (KEP-5007 GA)¶
For AI and GPU infrastructure teams, the biggest leap in v1.38 lands in resource.k8s.io/v1 (Dynamic Resource Allocation): both DRAPartitionableDevices and DRADeviceBindingConditions graduate to GA.
Scope Note: This lab publishes genuine
resource.k8s.io/v1DeviceClassandResourceSliceobjects to test the realkube-scheduler v1.38.0-rc.0allocation engine,sharedCountersmutual exclusion, andPreBindbinding gates directly at the control plane (without a physical vendor GPU node plugin injecting device files into containers).
4.1 Architecture & Reproducible ResourceSlice Manifests¶
flowchart LR
CS["ResourceSlice 1: sharedCounters<br/>gpu0-hw (141Gi / 100 CU)<br/>gpu1-hw (141Gi / 100 CU)"] --> DEV["ResourceSlice 2: devices<br/>gpu0-full | gpu0-mig-a | gpu0-mig-b<br/>gpu1-nvlink-gated (bindingConditions)"]
DEV --> SCH["kube-scheduler v1.38.0-rc.0<br/>DynamicResources Plugin"]
SCH -->|"KEP-4815: 70+70 <= 141Gi"| MIG["pod-mig1 + pod-mig2 Scheduled<br/>pod-full0 Blocked (Unschedulable)"]
SCH -->|"KEP-5007: PreBind Hold"| GATE["claim-fabric Reserved<br/>Event: BindingConditionsPending"]
GATE -->|"PATCH FabricReady=True"| OK["Bound to worker-2 (1,923 ms)"]
GATE -->|"PATCH FabricFailed=True"| ABORT["PreBind Aborted (FabricLinkError)"]
One important resource.k8s.io/v1 schema constraint to note: a single ResourceSlice cannot specify both sharedCounters and devices—you publish two slices under the same pool (resourceSliceCount: 2):
apiVersion: resource.k8s.io/v1
kind: DeviceClass
metadata:
name: dra-lab.aik8s.dev
spec:
selectors:
- cel:
expression: 'device.driver == "dra-lab.aik8s.dev"'
---
apiVersion: resource.k8s.io/v1
kind: ResourceSlice
metadata:
name: dra-lab-counters
spec:
driver: dra-lab.aik8s.dev
nodeName: worker-2
pool:
name: pool-worker-2
generation: 1
resourceSliceCount: 2
sharedCounters:
- name: gpu0-hw
counters:
memory:
value: 141Gi
compute-units:
value: "100"
- name: gpu1-hw
counters:
memory:
value: 141Gi
compute-units:
value: "100"
---
apiVersion: resource.k8s.io/v1
kind: ResourceSlice
metadata:
name: dra-lab-devices
spec:
driver: dra-lab.aik8s.dev
nodeName: worker-2
pool:
name: pool-worker-2
generation: 1
resourceSliceCount: 2
devices:
- name: gpu0-full
attributes:
profile:
string: "full-141g"
consumesCounters:
- counterSet: gpu0-hw
counters:
memory:
value: 141Gi
compute-units:
value: "100"
- name: gpu0-mig-a
attributes:
profile:
string: "mig-70g"
consumesCounters:
- counterSet: gpu0-hw
counters:
memory:
value: 70Gi
compute-units:
value: "50"
- name: gpu0-mig-b
attributes:
profile:
string: "mig-70g"
consumesCounters:
- counterSet: gpu0-hw
counters:
memory:
value: 70Gi
compute-units:
value: "50"
- name: gpu1-nvlink-gated
attributes:
profile:
string: "nvlink-fabric-141g"
bindsToNode: true
bindingConditions:
- FabricReady
bindingFailureConditions:
- FabricFailed
consumesCounters:
- counterSet: gpu1-hw
counters:
memory:
value: 141Gi
compute-units:
value: "100"
4.2 Verified Flow: Counter Mutual Exclusion & FabricReady / FabricFailed Gates¶

- Lab 3A (
KEP-4815Partitionable Shared Counters): pod-mig1andpod-mig2each requestprofile == "mig-70g"and schedule ontogpu0-mig-a(227.4 ms) andgpu0-mig-b(248.5 ms) on the same physicalgpu0-hwcounterSet (consuming140Gi / 100 CU).- Submitting
pod-full0requesting the overlapping whole-GPUprofile == "full-141g"is cleanly blocked (Unschedulable: cannot allocate all claims), preventing hardware overcommitment. - Deleting
pod-mig1andpod-mig2frees the counters andpod-full0immediately schedules ontogpu0-fullin222.0 ms! - Lab 3B (
KEP-5007Device Binding Conditions): - Submitting
pod-fabricclaiminggpu1-nvlink-gatedallocates and reservesclaim-fabric(status.allocationset togpu1-nvlink-gated,reservedForcount1), while holdingpod.spec.nodeName = Noneand emittingBindingConditionsPending: waiting for binding conditions for device. - Patching
FabricReady=Truevia--subresource=statusonclaim-fabric(simulating NVSwitch / Fabric Manager attachment) releases the gate and binds the Pod in1,923.3 ms! - Injecting
FabricFailed=True(reason: FabricLinkError) onclaim-fabric-failtriggers immediate PreBind abort so the Pod never lands on a degraded fabric:
BindingConditionsPending waiting for binding conditions for device on node worker-2
FailedScheduling running PreBind plugin "DynamicResources": device binding failed: claim=claim-fabric-fail, reason=FabricLinkError, message="Simulated NVLink fabric attachment failure"
5. Lab 4: kuberc v1 (KEP-3104 GA) & WebSockets (KEP-4006 GA)¶
Pairing kubectl v1.38.0-rc.0 with the upgraded cluster verified both CLI/streaming GA features along with two real behavioral gotchas:
5.1 kuberc Graduated to kubectl.config.k8s.io/v1 (Two Real Gotchas)¶
apiVersion: kubectl.config.k8s.io/v1
kind: Preference
aliases:
- name: nodesw
command: get
appendArgs:
- nodes
- -o
- wide
- Working invocation:
KUBERC=./kuberc-v1.yaml kubectl nodesw --context my-clustercleanly expands toget nodes -o wide. - Gotcha 1 (Flag placement): Putting global flags before an alias (
kubectl --context my-cluster nodesw) fails withError: flags cannot be placed before plugin name: --context; place global flags after the alias name. - Gotcha 2 (Breaking change reproduced): The legacy
namealias insidecredentialPluginAllowlistfromv1beta1is removed inv1(replaced bycommand). Passingnameproduces a strict decoding error:
kuberc: ignoring strict decoding error in kuberc-legacy-name.yaml: strict decoding error: unknown field "credentialPluginAllowlist[0].name"
error occurred while applying preferences misconfigured credential plugin allowlist: empty allowlist entry #1
5.2 KEP-4006: WebSockets Permanently Standard, Legacy Opt-Out Env Vars Removed¶
In v1.38, KUBECTL_REMOTE_COMMAND_WEBSOCKETS and KUBECTL_PORT_FORWARD_WEBSOCKETS are removed. Running kubectl exec -v=6 with KUBECTL_REMOTE_COMMAND_WEBSOCKETS=false confirms kubectl unconditionally negotiates WebSockets (204 ms):
$ KUBECTL_REMOTE_COMMAND_WEBSOCKETS=false kubectl -n k8s138-lab exec -v=6 pod-level-shared -c app -- echo "ws-ok"
round_trippers.go:632] "Response" verb="GET" url="https://.../exec?command=echo&command=ws-ok&container=app&stderr=true&stdout=true" status="101 Switching Protocols" milliseconds=204
websocket.go:134] "Subprotocol negotiated" protocol="v5.channel.k8s.io"
ws-ok
6. Lab 5: Live v1.37.2 → v1.38.0-rc.0 In-Place Upgrade & KEP-4033 Lessons¶
The figure below summarizes all 6 Pod-level /resize cgroup v2 convergence measurements alongside DRA scheduling, binding-gate, and WebSocket handshake latencies:

Upgrading our 3-node cluster (Anolis OS 8.8 + cgroup v2 + containerd 2.4.2 + Cilium without kube-proxy) in-place from v1.37.2 to v1.38.0-rc.0 surfaced 4 directly reusable operational takeaways:
KEP-4033StaticcgroupDriverCleanup:v1.38rejects staticcgroupDriver: systemdinKubeletConfigurationby default in favor of CRIRuntimeConfigdiscovery. RemovecgroupDriverfrom bothkube-system/cm/kubelet-configand each node's/var/lib/kubelet/config.yamlbefore restartingkubelet; live/configzconfirmsfailCgroupV1: Trueand auto-discoveredsystemd.- Preserve Custom CRI Sockets Across
kubeadm upgrade: If your nodes use a non-default containerd socket (e.g.,unix:///run/custom-containerd/containerd.sock), setcontainerRuntimeEndpointincm/kubelet-configand annotate every node withkubeadm.alpha.kubernetes.io/cri-socketbefore runningkubeadm upgrade, otherwisekubeadm upgrade nodewill overwrite/var/lib/kubelet/config.yamlwith an empty endpoint. - Complete Offline Image Bundle: Alongside the three
v1.38.0-rc.0control-plane images,kubeadmupgradesetcd:3.7.3-0(from3.7.0-0),coredns/coredns:v1.15.0(fromv1.14.6), and keepspause:3.10.2. Pre-importing these into containerd'sk8s.ionamespace allows a fully offlinekubeadm upgrade apply, andproxy.disabled: truecleanly skipskube-proxy. - Zero-Eviction Rolling Worker Upgrades: Backing up configs, running
kubeadm upgrade node, atomically swapping thekubeletbinary, and restartingkubeletkeeps existing stateful pods and local-PV workloads running continuously insidecontainerdwith zero restarts.
Raw Data, Official KEPs & Related Reading¶
- Complete sanitized experimental dataset (all 3 rounds per cell, DRA events, and feature gate inventory):
results.json - Official KEP design docs and tracking issues:
KEP-2837: Pod-Level Resource Specification (Tracking Issue)KEP-5419: In-Place Pod-Level Resources Vertical Scaling (Tracking Issue)KEP-4815: DRA Partitionable Devices (Tracking Issue)KEP-5007: DRA Device Binding Conditions (Tracking Issue)KEP-3104: Separate kubectl User Preferences (kuberc) (Tracking Issue)KEP-4006: Transition SPDY to WebSockets (Tracking Issue)KEP-4033: DiscoveringcgroupDriverfrom CRI (Tracking Issue)- Prior DRA deep dive: Kubernetes v1.37 DRA Topology Alignment, VRAM Slicing & Fault Self-Healing
- GPU scheduling practice: Volcano v1.16 GPU Scheduling & Queue Reclamation Benchmark