SCHED-1041: Pre-create GPU lib placeholders so a failing nvidia-container-cli cannot break the cluster#2703
Merged
Conversation
9be495d to
9be3791
Compare
46e459a to
5f6b894
Compare
884787f to
daba8dd
Compare
rdjjke
reviewed
Jul 8, 2026
rdjjke
reviewed
Jul 8, 2026
daba8dd to
8ae4151
Compare
…ults so one worker's failing nvidia-container-cli cannot break NVML on the whole cluster.
8ae4151 to
f82840b
Compare
…esystem filter since stray placeholders are harmless, and scope the umask in a subshell instead of forcing directory modes
rdjjke
reviewed
Jul 10, 2026
rdjjke
approved these changes
Jul 10, 2026
This was referenced Jul 10, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
At cold cluster bring-up all workers run
nvidia-container-cliagainst the shared jail at the same moment. The CLI creates 0-byte placeholder files on the shared jail and bind-mounts the host driver libs over them. Confirmed in 7 e2e reproductions:mount error: file creation failed: .../gsp_ga10x.bin: file exists), its container restarts, and the solo re-run succeeds — this worker always recovers by accident.prepull-container-imagefails the bring-up, or multi-node GPU jobs fail later withfile too short.The second half is not limited to bring-up races: any CLI failure on any worker at any time deletes the placeholders under the whole fleet's mounts.
Solution
Pre-create the placeholders as small non-empty marker files before the CLI runs (
precreate_gpu_placeholdersincomplement_jail.sh):nvidia-container-cli listat runtime, so driver upgrades are handled automatically; the/devand/runentries resolve to objects already created by the kernel and system daemons, so the existence check skips them;The CLI result is verified instead of trusted: every mount the CLI created must stay attached and show real content by path (by size — a placeholder passes plain existence checks), whatever file set the enabled driver capabilities select. The
libnvidia-ml.so.1soname is additionally verified after ldconfig (repaired by a local ldconfig run if missing) when NVML is mounted. On any failure the container exits so kubelet restarts it.The two places that treated "empty file" as "placeholder" (the CPU-worker libdummy mounts and the populate_jail cleanup) now match by size and versioned lib name (
lib*.so.*smaller than 64 bytes), covering both old 0-byte and new marker placeholders while leaving the jail image's other small files (ncurses linker scripts, glibc stub archives) alone.Testing
[nvml]log telemetry stays for verifying this in production.Release Notes
Fix: GPU driver lib placeholders in the shared jail are now pre-created as non-empty files, so concurrent
nvidia-container-cliruns never race to create them and a failing run can no longer delete them from under the other workers' bind mounts — fixing intermittent NVML load failures ("cannot open shared object file" / "file too short") on multi-worker bring-up.