Fedora 38 and CUDA Tookit issues installing/compiling


I’d been running the latest Nvidia drivers on Fedora 38 along with CUDA (basic) via rpmfusion non-free repo and it’s was running great. I decided to try some dev work out though and needed to install the NVIDIA CUDA toolkit on my system which I tried to do following the RPMFusion guide here. I’m not sure if I did it correctly though, these are the steps they outline (the website says f35 but I swapped for f37):

sudo dnf config-manager --add-repo https://developer.download.nvidia.com/compute/cuda/repos/fedora37/x86_64/cuda-fedora37.repo
sudo dnf clean all
sudo dnf module disable nvidia-driver
sudo dnf -y install cuda

The thing is that they don’t specify what packages you should have installed before you use run sudo dnf -y install cuda. As I already had the rpmfusion cuda driver installed (non toolkit) I was concerned about overwriting it and causing issues, so I removed it before running the commands above. This appears to have worked for the most part, although there are a number of errors when I run a dnf update:

sunny@Fed sudo dnf update
Repository vivaldi is listed more than once in the configuration
Last metadata expiration check: 0:02:27 ago on Mon 13 Nov 2023 22:48:37 GMT.
Dependencies resolved.

 Problem: package cuda-12-3-12.3.0-1.x86_64 from cuda-fedora37-x86_64 requires cuda-runtime-12-3 >= 12.3.0, but none of the providers can be installed
  - package cuda-12.3.0-1.x86_64 from cuda-fedora37-x86_64 requires cuda-12-3 >= 12.3.0, but none of the providers can be installed
  - package cuda-runtime-12-3-12.3.0-1.x86_64 from cuda-fedora37-x86_64 requires cuda-drivers >= 545.23.06, but none of the providers can be installed
  - cannot install the best update candidate for package cuda-12.2.2-1.x86_64
  - package cuda-drivers-545.23.06-1.x86_64 from cuda-fedora37-x86_64 is filtered out by modular filtering
 Package                              Architecture              Version                      Repository                               Size
Skipping packages with broken dependencies:
 cuda-12-3                            x86_64                    12.3.0-1                     cuda-fedora37-x86_64                    7.4 k
 cuda                                 x86_64                    12.3.0-1                     cuda-fedora37-x86_64                    7.3 k
 cuda-runtime-12-3                    x86_64                    12.3.0-1                     cuda-fedora37-x86_64                    7.3 k

Transaction Summary
Skip  3 Packages

Nothing to do.

The issue comes when I try to compile things, there’s complaints about my gcc binary being incompatible with cuda and so I tried to use a conda environment to install a compatible gcc and g++ (version 12.2), however that has failed as well with issues related to glibc incompatibilities. So i’m almost there.

My question is, do you know if I can install the nvidia official fedora 37 version of CUDA Toolkit alongside the rpmfusion version which is fully compatible?

I’m clutching at straws tbh though, I’m not sure why nvidia is treating fedora as a third class citizen and not providing updates for cuda toolkit!!

Any help appreciated :)


bump! anyone??

no idea why Nvidia isn’t supporting Fedora > F37 atm? Are plans in place for this or should I move to another distro??

Fedora 37 is the latest officially supported version of Fedora at this time, see here for CUDA 12.3 Update 1 linux support.

If you study the archived versions of those documents, you will see that over time, newer CUDA versions tend to support newer linux versions. So its possible that F38 or a newer Fedora might be supported in a future CUDA release, but I have no information about that, at this time.

Thanks Robert,

Good to know. Hope Nvidia can speed up the release cycle for Fedora. Seems wild to have such delays, it’s been just over a year and we have Fedora 39 now.

Could you or someone please escalate this issue as my company is stuck on F37. I’ve been beta testing F38 but have so far not been able to get CUDA to work. Really appreciate your help


I really don’t want to sound as if this is a complaint, because, after all how brilliant is it that we can have the Cuda software for free, and that there are these excellent, authoritative and interesting forums to help with it. That said the support for Fedora does seem to have got into a bit of a muddle. If you follow the link in Robert Crovella’s reply:

Fedora 37 is the latest officially supported version of Fedora at this time, see here for CUDA 12.3 Update 1 linux support.

you can find this:
CUDA supports the latest Fedora release version. For Fedora release timelines, visit Fedora Linux Releases :: Fedora Docs. (this is in a document for 12.3 update 1 - although the equivalent doc for update 2 seems to indicate the same).

This statement is not correct as the latest version of fedora is 39 and elsewhere in the above document, as Robert Crovella has said the currently supported version is 37. If the Nvidia document had said “a current version” it would have been better, but still incorrect, as 37 was end-of-life (no further updates - critical or otherwise) since about a month ago. For myself, I can keep the cuda machine off the network until it can be updated (it is a real pain) but for many that will be impossible. I was hoping update 2 would fix this but no such luck.

Just to make things even more confusing (and this is not Nvidia’s fault, clearly) if you follow the Fedora link it says 39, 38, AND 37 are supported versions, which is also incorrect.

Clearly it would be unreasonable to expect the latest release to be supported, you already do a brilliant job of keeping up with so many choices of OS.

I accept that by choosing Fedora the upgrade cycle is more aggressive than some other choices, and there isn’t the safety net of an LTS release. However it would at least improve the overall situation if at least some of the confusion could be cleared up.

Thanks again for Cuda, the forums, and the opportunity to comment.

PS Since I wrote the above comments, Fedora have now changed their page (albeit a month late) to F37 EOL

Decided it was a good time to look into alternative distributions. Currently testing out NixOS, they have their own cuda-toolkit package so no more of this nonsense of being at the mercy of Nvidia, stuck on ancient drivers and tools.

I’ll post here if the tests are successful.

Wish there was a viable alternative to Nvidia/Apple, I would jump in a heartbeat