An NVIDIA kernel module ‘nvidia-uvm’ appears to already be loaded in your kernel

I am building a Docker image and I need a specific version of TensorRT with nvidia-driver-455.38 (yes, I need exactly the 455.38 not any other 455 drivers).

Dockerfile:

FROM nvcr.io/nvidia/tensorrt:20.09-py3

SHELL ["/bin/bash", "-xo", "pipefail", "-c"]
ENV DEBIAN_FRONTEND noninteractive

RUN apt-get update && apt-get install -y kmod
RUN curl https://us.download.nvidia.com/XFree86/Linux-x86_64/455.38/NVIDIA-Linux-x86_64-455.38.run -o NVIDIA-Linux-x86_64-455.38.run
RUN chmod +x ./NVIDIA-Linux-x86_64-455.38.run
RUN ./NVIDIA-Linux-x86_64-455.38.run --silent

I have the following error:

root@07c4fbe6e9f4:/workspace# ./NVIDIA-Linux-x86_64-455.38.run --silent
Verifying archive integrity... OK
Uncompressing NVIDIA Accelerated Graphics Driver for Linux-x86_64 455.38..................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................

ERROR: An NVIDIA kernel module 'nvidia-uvm' appears to already be loaded in your kernel.  This may be because it is in use (for example, by an X server, a CUDA program, or
       the NVIDIA Persistence Daemon), but this may also happen if your kernel was configured without support for module unloading.  Please be sure to exit any programs
       that may be using the GPU(s) before attempting to upgrade your driver.  If no GPU-based programs are running, you know that your kernel supports module unloading,
       and you still receive this message, then an error may have occured that has corrupted an NVIDIA kernel module's usage count, for which the simplest remedy is to
       reboot your computer.


ERROR: Installation has failed.  Please see the file '/var/log/nvidia-installer.log' for details.  You may find suggestions on fixing installation problems in the README
       available on the Linux driver download page at www.nvidia.com.

Details:

root@07c4fbe6e9f4:/workspace# cat '/var/log/nvidia-installer.log'
nvidia-installer log file '/var/log/nvidia-installer.log'
creation time: Wed Aug  4 11:02:14 2021
installer version: 455.38

PATH: /opt/tensorrt/bin:/usr/local/mpi/bin:/usr/local/nvidia/bin:/usr/local/cuda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/ucx/bin

nvidia-installer command line:
    ./nvidia-installer
    --silent

Using built-in stream user interface
-> Detected 16 CPUs online; setting concurrency level to 16.
ERROR: An NVIDIA kernel module 'nvidia-uvm' appears to already be loaded in your kernel.  This may be because it is in use (for example, by an X server, a CUDA program, or the NVIDIA Persistence Daemon), but this may also happen if your kernel was configured without support for module unloading.  Please be sure to exit any programs that may be using the GPU(s) before attempting to upgrade your driver.  If no GPU-based programs are running, you know that your kernel supports module unloading, and you still receive this message, then an error may have occured that has corrupted an NVIDIA kernel module's usage count, for which the simplest remedy is to reboot your computer.
ERROR: Installation has failed.  Please see the file '/var/log/nvidia-installer.log' for details.  You may find suggestions on fixing installation problems in the README available on the Linux driver download page at www.nvidia.com.

How can I solve this?

Before I used to install the driver using

RUN apt-get update && apt-get install -y software-properties-common ubuntu-drivers-common lshw
RUN add-apt-repository ppa:graphics-drivers/ppa
RUN apt install -y nvidia-driver-455

but that does not allow me to specify the specific driver build (455.38).

Thank you!

1 Like

Hi,
Please refer to the installation steps from the below link if in case you are missing on anything

Also, we suggest you to use TRT NGC containers to avoid any system dependency related issues.

Thanks!

Hi @NVES , as you can see I am using the TRT NGC container however I am having issues when installing the drivers (see above). I can’t find any solution in the link you provided.

Hi @mfoglio,

We recommend you to post your concern here to get better help.

Thank you.

Thanks, moved here An NVIDIA kernel module ‘nvidia-uvm’ appears to already be loaded in your kernel

Hi @mfoglio, how you managed to get through this issue please?