fix(inference): find nvidia-smi on WSL - #8904
Conversation
Signed-off-by: Charan Jagwani <cjagwani@nvidia.com>
Code Coverage OverviewLanguages: TypeScript TypeScript / code-coverage/pluginThe overall coverage in commit df4d2a6 in the TypeScript / code-coverage/cliThe overall coverage in commit df4d2a6 in the Show a code coverage summary of the most impacted files.
Updated |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Enterprise Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThe change adds WSL-aware NVIDIA SMI discovery. NIM GPU detection and managed vLLM checks now try the PATH command first and the stock WSL driver path when required. ChangesWSL NVIDIA SMI discovery
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant NIM
participant captureNvidiaSmi
participant runCapture
participant GPU
NIM->>captureNvidiaSmi: request GPU or driver data
captureNvidiaSmi->>runCapture: run PATH nvidia-smi
runCapture->>GPU: query NVIDIA SMI
GPU-->>runCapture: output or error
captureNvidiaSmi->>runCapture: retry WSL driver path when needed
runCapture->>GPU: query /usr/lib/wsl/lib/nvidia-smi
GPU-->>runCapture: NVIDIA SMI output
runCapture-->>NIM: first non-empty output
Possibly related PRs
Suggested labels: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
PR Review Advisor — No blocking findings reportedAdvisor assessment: No blocking advisor findings reported Model lanes
2 additional E2E selections from the second opinionAdvisory only. The primary lane did not select these E2E jobs or targets.
Second-opinion terminology and E2E selections are advisory. Live E2E does not run automatically for pull requests. 2 semantic terminology decisionsTerminology decisions are advisory. They affect the assessment only when a separate finding identifies concrete semantic impact.
E2E guidanceAdvisory only. A maintainer can dispatch the default E2E suite for the commit under review. Recommended E2E: Manual-only E2E: 1 warning · 0 suggestionsWarningsWarnings do not block.
|
cv
left a comment
There was a problem hiding this comment.
Accepted issue #8794 is linked and In Progress. The complete eight-file change preserves PATH precedence, adds only the fixed WSL NVIDIA driver path, updates all relevant GPU and managed-vLLM probes, and adds focused regression coverage. All nine security categories pass: execution uses argv transport, the shell lookup receives a fixed candidate as $1, and no credential, policy, dependency, or authorization boundary changes. No competing open PR, unresolved review finding, compatibility defect, or documentation gap was found.
Summary
Stock WSL2 guests can now detect NVIDIA GPUs without adding
/usr/lib/wsl/libtoPATH. NVIDIA probes keep the existing PATH command authoritative, then use the stock WSL driver shim only on WSL so preflight can enable GPU passthrough and managed vLLM can pass its prerequisite and compute-capability checks.Related Issue
Fixes #8794
Changes
nvidia-smito/usr/lib/wsl/lib/nvidia-smiin the existing GPU trust layer.nim.test.tsline budget from 2068 to its new measured value of 2067 after moving the new regression into the focused GPU-detection suite.Type of Change
Quality Gates
Documentation Writer Review
no-docs-neededdocs/get-started/windows-preparation.mdx,docs/inference/set-up-vllm.mdx,docs/inference/set-up-nvidia-nim.mdx, anddocs/reference/troubleshooting.mdxalready describe the supported WSL/GPU contract without requiringnvidia-smiPATH configuration.DGX Station Hardware Evidence
Verification
Signed-off-by:line and every commit appears asVerifiedin GitHubpre-commit,commit-msg, andpre-pushhooks passed, ornpm run validate:prpassed after refreshingorigin/mainwhen hooks were skipped or unavailablenpx vitest run --project cli src/lib/inference/gpu-trust.test.ts src/lib/inference/nim.test.ts src/lib/inference/nim-igpu-compute-constrained.test.ts src/lib/inference/nim-driver-version.test.ts src/lib/inference/vllm-compute-capability.test.ts(124 passed)npm run checks:repository,npm run typecheck:cli, andnpm run test-size:checkpassed.npm run docsbuilds without warnings (doc changes only)Signed-off-by: Charan Jagwani cjagwani@nvidia.com