NVIDIA drivers in Ubuntu Classic

Hi all,

I am working to make an nvidia snap for Ubuntu Classic, and I would like to hear your opinion on how to best deal with the current problems:

  1. We cannot distribute pre-built kernel modules because of the licence. DKMS is also not available, but we need a way to build the modules for the current kernel and for any future kernel updates.

  2. We need to blacklist the nouveau driver in the initramfs.

  3. We need to ship a udev rule so that a) we can tag the device as master-of-seat (so that logind is happy), and b) we can load the additional kernel modules and create some devices.

  4. Create a user and a group for the nvidia-persistenced tool.

  5. Distribute its libraries (EGL, GL, OpenCL, Vulkan, etc.) and make them available to other snaps. I was thinking of distributing the libraries using a content interface. I have created a mesa-runtime snap that does the same, and this will save us the trouble of including driver specific libraries in each snap that needs them. Better ideas are welcome, of course.

Note: a similar (although simpler) problem affects the Broadcom wireless driver

Thank you in advance for your help.

2 Likes

Hey

I’d like to participate as this is also something that snap-confine currently does but I wanted to change how that operates after discovering shortcomings in the design. I’ll reply with a longer analysis here when I have a moment away from priority tasks.

I look forward to that. Thanks!

Just curious what the latest is on this discussion? @zyga-snapd do you have that analysis that you mentioned in your last reply?

I have but today I’m a bit too tired to express those. I will circle back (probably next week).