Installing Cuda 12.1 on ubuntu 22.04.3 LTS

Hi !

I’ m trying to install 12.1.1 as it seems to be the latest compatible with the latest tensorrt on a fresh new latest ubuntu 22.04
Unfortunately, the cuda 12.1.1 seems to force an installation of the 530 driver that is normally not visible in the “software update” of “additional drivers” of ubuntu 22.04. Then the install breaks as the 530 driver doesn’ t seem to be compatible with the latest kernel of ubuntu.

Building initial module for 6.5.0-17-generic
ERROR: Cannot create report: [Errno 17] File exists: ‘/var/crash/nvidia-kernel-source-530.0.crash’

and in the crash it says :

var/lib/dkms/nvidia/530.30.02/build/common/inc/nv-mm.h:88:16: error: too many arguments to function ‘get_user_pages’
88 | return get_user_pages(current, current->mm, start, nr_pages, write,
| ^~~~~~~~~~~~~~
./include/linux/mm.h:2430:6: note: declared here
2430 | long get_user_pages(unsigned long start, unsigned long nr_pages,

my configuration:

lsb_release -a

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 22.04.3 LTS
Release: 22.04
Codename: jammy

uname -a
Linux fred-IdeaPad-Gaming-3-16ARH7 6.5.0-17-generic #17~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Tue Jan 16 14:32:32 UTC 2 x86_64 x86_64 x86_64 GNU/Linux

Thanks for your help

Thank you for this message. Can you please try to install r550 from here:
and then, install the CUDA 12.1 toolkit from NVIDIA’s website:

(select runfile download option), and when installing, manually unselect “CUDA Driver” in the command-line UI.

Side question: did you manually install the Linux 6.5 kernel, or did it come with Ubuntu? I did some research, and it seems your laptop model has a Samsung SSD that causes system crashes with a 6.2 kernel, so I am wondering if you intentionally installed 6.5 of if it came as-is when you installed Ubuntu (through the OEM kernels).

Hi ! Thank you a lot for your answer.
I after reading some other channels, I finally found also the runtime solution unselecting the driver install.
I still had a driver 535 installed, so it seems like it worked without installing the 550.

Actually as I said, I just installed a new fresh ubuntu, then I did apt update and apt upgrade and then I installed the 535 driver from the ubuntu gui, and then ran the runtime installation removing the driver install, and it finally worked.
Thanks a lot, feel free to ask me any additional question if it helps you too.

Proceeding with the installation of my setup I see that there is a dead link in the documentation of the installation of cudnn

cuDNN 8.9.0

I managed to find another link:

Anyway, it seems like the way to install cuda as you recommend doesn’ t allow me to install cudnn afterward, as I followed the documentation here and it gives me this error :

fred@fred-IdeaPad-Gaming-3-16ARH7:~$ sudo apt-get -y install cudnn9-cuda-12
Reading package lists… Done
Building dependency tree… Done
Reading state information… Done
E: Unable to locate package cudnn9-cuda-12

after an update, listing the depedencies, it seems like nothing is available

apt list | grep cudnn

WARNING: apt does not have a stable CLI interface. Use with caution in scripts.

nvidia-cudnn/jammy amd64

Hi, @maujart

This is forum for develop tools - Sanitizer, and we are not familiar with cudnn release and installation. Please ask more details in cudnn forum directly. Thanks !

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.