diff --git a/data_gpu/driver/README.md b/data_gpu/driver/README.md index fe04c8d..002715e 100644 --- a/data_gpu/driver/README.md +++ b/data_gpu/driver/README.md @@ -14,10 +14,14 @@ $ sudo apt-get install nvidia-cuda-toolkit $ sudo ./comp_and_load_drivers.sh ``` -If NVLink support is required, install cuda-drivers-fabricmanager- as well. However, as of Febuary 2024, the latest version of fabricmanager is 535. -When it becomes available on Ubuntu, install with: +Disable the Xserver and nvidia-persistenced to prevent rmmod due to Module XXX is in use by: YYY +because the Nvidia driver gets loaded by default at startup -``` -$ sudo apt-get install cuda-drivers-fabricmanager-545 -``` +https://forums.developer.nvidia.com/t/cant-install-new-driver-cannot-unload-module/63639 +```bash +$ sudo systemctl disable gdm # For GNOME Display Manager +$ sudo systemctl disable lightdm # For LightDM +$ sudo systemctl disable sddm # For SDDM +$ sudo systemctl disable nvidia-persistenced +``` diff --git a/data_gpu/driver/comp_and_load_drivers.sh b/data_gpu/driver/comp_and_load_drivers.sh index c2e4c18..e32c65c 100755 --- a/data_gpu/driver/comp_and_load_drivers.sh +++ b/data_gpu/driver/comp_and_load_drivers.sh @@ -20,19 +20,12 @@ echo "Using Nvidia path: $NVIDIA_PATH" RET_DIR=$PWD echo "Using RET_DIR: $RET_DIR" -# Stop the Xserver and nvidia-persistenced to prevent rmmod due to Module XXX is in use by: YYY -# https://forums.developer.nvidia.com/t/cant-install-new-driver-cannot-unload-module/63639 -systemctl stop gdm # For GNOME Display Manager -systemctl stop lightdm # For LightDM -systemctl stop sddm # For SDDM -systemctl stop nvidia-persistenced - # Remove existing Nvidia modules (if any) -/usr/sbin/rmmod datagpu -/usr/sbin/rmmod nvidia-drm -/usr/sbin/rmmod nvidia-uvm -/usr/sbin/rmmod nvidia-modeset -/usr/sbin/rmmod nvidia +/usr/sbin/rmmod datagpu 2>&1 +/usr/sbin/rmmod nvidia-drm 2>&1 +/usr/sbin/rmmod nvidia-uvm 2>&1 +/usr/sbin/rmmod nvidia-modeset 2>&1 +/usr/sbin/rmmod nvidia 2>&1 # Go to nvidia path and build Nvidia driver cd "$NVIDIA_PATH" || { echo "Error: Failed to change directory to $NVIDIA_PATH"; exit 1; }