HOW-TO: Get CUDA and hardware acceleration working on OpenSUSE Tumbleweed
It's been an obnoxiously annoying week after reloading my main desktop. I had a very functional desktop, prior, but zypper would hang attempting to update nvidia-compute-G06 and a combination of "snapper doesn't snapshot /opt" and "I took too many snapshots", I ended up with a mostly non-working system that I couldn't get back to a state that wasn't stretching my text in low resolution across my ultrawide monitor. I had a few other problems with the machine, prior, so I decided to back up the important parts and reload.
I was pretty happy with how easily I was able to get the CUDA components installed (just visit the usual NVIDIA driver install page and follow the directions under CUDA.
But I digress ...
This barely qualifies as help and I feel stupid
I was able to get everything CUDA related working very quickly, but it left me without nvidia-video-G06, which means X11 was laggy and Wayland was completely unusable (software rendered). Yeah, I know, wayland/nvidia is a path guarded by dragons, but I've had them both cooperating just fine in every prior installation. Attempting to install the driver brought up an issue about compatibility between the nvidia-open-driver-G06-signed-cuda-kmp-default (yes, I'm running kernel-default not kernel-longterm) and the only options were to break or not install the package.
And I puzzled over it for quite some time...
I'm used to zypper being pretty intelligent with things. I (wrongly) assumed that if the right package were actually available, it would use it. To make matters more puzzling, it was complaining that the nvidia-video-G06 that it wanted to install was a much older version than the nvidia-open-driver-G06-signed-cuda-kmp-default that I had installed. The main reason I went down this path in the first place was a desire to update the Nvidia proprietary driver to the latest version and the version it insisted installing was older than the one I had running on my desktop prior to reloading.
So here's the solution that worked for the 580.126.16_k6.19.3_1-1.2 version. Ready for this?
sudo zypper in nvidia-video-G06.x86_64 = 580.126.16
That's (F-ing) it.
I'm so used to things "just working" in Tumbleweed land (I've been running it for ten years and it's rarely given me trouble) that I didn't bother trying the most obvious solution. I had assumed zypper would have looked at what was available and handled that on its own. I swore I've seen it do that in the past and can't believe I've never had this specific problem in the last decade. GNU/Linux distributions have a way of improving one's humility.
A few more tips
I'm quite used to handling these problems by doing a quick Google search and following someone else's grief. This one was surprisingly difficult to find a solution to. Usually, that means I have a problem that's rare enough or specific enough to my configuration that nobody thought to complain about it. I'm a little used to that with Tumbleweed. It's a rolling distro and seemingly anything that's not Ubuntu isn't used by enough people to provide a wealth of (bad) solutions to common problems. Unfortunately, this was more likely a case that people running it didn't need help fixing this problem. It was obvious. So I'm posting the obvious in case there's another yokel like me out there pulling out their hair. Rule #2: If it's not on Google, it's because it's too easy of a problem to fix.
This solution might give you trouble, though, if there's not a package version matching your driver installation, so here's a few more things to try if you run into that:
First, run zypper se --details nvidia-video-G06, that will produce a list of every package version available from your installed repositories. Don't see it there? run that same command against the nvidia-open-driver-G06-signed-cuda-kmp-default package (beware, the version includes the required kernel version -- you'll want to uname -a to make sure you're getting the one that matches the kernel you have installed). You may need to downgrade (or upgrade) that driver, first.
If you have to change the kernel driver, reboot before you add nvidia-video-G06 and make sure you didn't just break the driver installation. That seems to be a frequent issue -- every package related to NVidia that has the usual NVidia driver version style MUST match (and if it's got a
Finally, if you get it all working, do yourself a favor and lock the kernel package with zypper al kernel-default. It's probably a good idea to do that with all of the Nvidia related pieces. It's not unusual for the kernel to receive an upgrade before there's a nvidia-open-driver-G06-signed-*-default driver ready for it. Just keep an eye on the available versions and unlock it when you can upgrade it. It's advisable to switch to the kernel-longterm package and avoid using kernel-default. I'd done that in my previous load because of similar problems with the zfs package, but I wiped my old Ubuntu partition and had no need of zfs this time around.