Add vGPU regional GCS download bypass to Ubuntu driver installer and align Autopilot NRI device injector - #625
Open
jkru3 wants to merge 1 commit into
Open
Conversation
…align Autopilot NRI device injector
Ubuntu Driver Installer (`nvidia-driver-installer/ubuntu/entrypoint.sh`):
- Add is_vgpu() to detect fractional `g4-standard-*` GCE machine types via metadata and `/etc/nvidia/gpu_fraction_divisor.txt`
- Add `configure_vgpu_download()` to dynamically resolve the local GCP region (`metadata.google.internal/computeMetadata/v1/instance/zone`) and construct regional GCS mirror URL (`gs://cos-nvidia-gpu-drivers-\${region}/NVIDIA-Linux-x86_64-580.126.09-grid-gcp.run`)
- Update `download_nvidia_installer()` to fetch the GCE instance metadata ADC access token and attach `Authorization: Bearer \${token}` for authenticated GCS runfile downloads
- Update `download_kernel_src()` to detect host kernel headers directly at `/root/usr/src/linux-headers-\${KERNEL_VERSION}` (or `/root/lib/modules/.../build`), skipping legacy container apt-get calls when running on modern GKE Ubuntu 24.04 nodes
- Update `run_nvidia_installer()` and `update_host_ld_cache()` to stop services and unload active kernel modules (`rmmod -f ecc nvidia_uvm nvidia_drm nvidia_modeset nvidia`), pass `--no-questions` and `--kernel-source-path`, write 8 to gpu_fraction_divisor.txt, and synchronize compiled libraries to `\${NVIDIA_INSTALL_DIR_HOST}/lib64` (`/home/kubernetes/bin/nvidia/lib64/`)
NRI Device Injector (`nri_device_injector/nri-device-injector-autopilot.yaml`):
- Add `nvidia-rtx-pro-6000-vws` to `nodeSelectorTerms` under `matchExpressions: cloud.google.com/gke-accelerator`, bringing Autopilot to parity with standard `nri-device-injector.yaml` so character devices (`/dev/nvidia-caps/*`) are injected into vGPU container namespaces across all cluster modes
Change-Id: Ic7dd70954322d0585ef2c1d5afc7c3613645fd03
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.
Ubuntu Driver Installer (
nvidia-driver-installer/ubuntu/entrypoint.sh):g4-standard-*GCE machine types via metadata and/etc/nvidia/gpu_fraction_divisor.txtconfigure_vgpu_download()to dynamically resolve the local GCP region (metadata.google.internal/computeMetadata/v1/instance/zone) and construct regional GCS mirror URL (gs://cos-nvidia-gpu-drivers-\${region}/NVIDIA-Linux-x86_64-580.126.09-grid-gcp.run)download_nvidia_installer()to fetch the GCE instance metadata ADC access token and attachAuthorization: Bearer \${token}for authenticated GCS runfile downloadsdownload_kernel_src()to detect host kernel headers directly at/root/usr/src/linux-headers-\${KERNEL_VERSION}(or/root/lib/modules/.../build), skipping legacy container apt-get calls when running on modern GKE Ubuntu 24.04 nodesrun_nvidia_installer()andupdate_host_ld_cache()to stop services and unload active kernel modules (rmmod -f ecc nvidia_uvm nvidia_drm nvidia_modeset nvidia), pass--no-questionsand--kernel-source-path, write 8 to gpu_fraction_divisor.txt, and synchronize compiled libraries to\${NVIDIA_INSTALL_DIR_HOST}/lib64(/home/kubernetes/bin/nvidia/lib64/)NRI Device Injector (
nri_device_injector/nri-device-injector-autopilot.yaml):nvidia-rtx-pro-6000-vwstonodeSelectorTermsundermatchExpressions: cloud.google.com/gke-accelerator, bringing Autopilot to parity with standardnri-device-injector.yamlso character devices (/dev/nvidia-caps/*) are injected into vGPU container namespaces across all cluster modesChange-Id: Ic7dd70954322d0585ef2c1d5afc7c3613645fd03