Nvidia on Ubuntu: Difference between revisions
Add details about what I did - but I'm not sure what I did that worked and whether it will survive a reboot, and whether I will get my kubuntu desktop back |
use Subpages template |
||
| (4 intermediate revisions by 2 users not shown) | |||
| Line 4: | Line 4: | ||
Why not just continue to use [https://nouveau.freedesktop.org/index.html Nouveau], a project of the [https://www.freedesktop.org/wiki/ freedesktop] community? I mean "if it ain't broke, don't fix it" - right? In principle, I'd very much like to use nouveau. I'm not even sure that any alternative is "better" in any way - especially since ''I am not a gamer''<ref>I'm not opposed in any way, I just don't have the time to add another hobby. This is a clarifying statement for my use-case, and therefore, requirements.</ref>. My use case is to get the best performance from local LLMs. As I become familiar with the methods to switch video drivers reliably, I intend to run benchmarks and explore the benefits of one configuration vs another. | Why not just continue to use [https://nouveau.freedesktop.org/index.html Nouveau], a project of the [https://www.freedesktop.org/wiki/ freedesktop] community? I mean "if it ain't broke, don't fix it" - right? In principle, I'd very much like to use nouveau. I'm not even sure that any alternative is "better" in any way - especially since ''I am not a gamer''<ref>I'm not opposed in any way, I just don't have the time to add another hobby. This is a clarifying statement for my use-case, and therefore, requirements.</ref>. My use case is to get the best performance from local LLMs. As I become familiar with the methods to switch video drivers reliably, I intend to run benchmarks and explore the benefits of one configuration vs another. | ||
== Status == | |||
As of 2025-07-03, I'm still not running with an NVIDIA driver. According to [https://www.reddit.com/r/Ubuntu/comments/1li7wg7/how_do_i_install_nvidiadriver575_correctly/ a Reddit thread] just days ago, it's always been rather messy getting the right system together. I should "upgrade your system either to Ubuntu 25.04 for Wayland experience and no working suspend to RAM, or to 24.04 if you need suspend to RAM, but are Ok with using X11 instead of Wayland." | |||
Since I'm on 24.04, and I've tried using X11 instead of Wayland without success, I plan to ensure my home directory is on its own partition and reinstall the OS to 25.04 | |||
== Opposite == | == Opposite == | ||
| Line 19: | Line 24: | ||
'''OpenGL version''' string: 4.3 (Compatibility Profile) Mesa 24.2.8-1ubuntu1~24.04.1 | '''OpenGL version''' string: 4.3 (Compatibility Profile) Mesa 24.2.8-1ubuntu1~24.04.1 | ||
If you are on a TTY (without a display), <code>lspci</code> shows the same info | |||
<code>lspci | grep VGA</code> | <code>lspci | grep VGA</code> | ||
| Line 31: | Line 36: | ||
'''OpenGL version''' string: 4.5 (Compatibility Profile) Mesa 24.2.8-1ubuntu1~24.04.1 | '''OpenGL version''' string: 4.5 (Compatibility Profile) Mesa 24.2.8-1ubuntu1~24.04.1 | ||
LLVMpipe is a software rasterizer within the Mesa 3D graphics library that utilizes the LLVM compiler infrastructure to perform rendering entirely on the CPU. It acts as a software fallback when a dedicated GPU or its drivers are unavailable or malfunctioning, allowing OpenGL applications to run without hardware acceleration. Essentially, LLVMpipe takes over the rendering process when the GPU can't or shouldn't be used. | [https://docs.mesa3d.org/drivers/llvmpipe.html LLVMpipe] is a software rasterizer within the Mesa 3D graphics library that utilizes the LLVM compiler infrastructure to perform rendering entirely on the CPU. It acts as a software fallback when a dedicated GPU or its drivers are unavailable or malfunctioning, allowing OpenGL applications to run without hardware acceleration. Essentially, LLVMpipe takes over the rendering process when the GPU can't or shouldn't be used. | ||
If dpkg shows xserver-xorg-video-'''nouveau is installed''', then you can switch to it from e.g. "Driver Manager" in Settings. | If dpkg shows xserver-xorg-video-'''nouveau is installed''', then you can switch to it from e.g. "Driver Manager" in Settings. | ||
| Line 63: | Line 68: | ||
systemctl list-units --type service --all | grep nvidia | systemctl list-units --type service --all | grep nvidia | ||
nvidia-persistenced.service loaded active running NVIDIA Persistence Daemon | nvidia-persistenced.service loaded active running NVIDIA Persistence Daemon | ||
</pre>dkms shows that kernel modules are installed for two kernels<pre> | </pre>[[DKMS|dkms]] shows that kernel modules are installed for two kernels<pre> | ||
dkms status | dkms status | ||
nvidia/575.57.08, 6.8.0-60-generic, x86_64: installed (Original modules exist) | nvidia/575.57.08, 6.8.0-60-generic, x86_64: installed (Original modules exist) | ||
| Line 222: | Line 227: | ||
=== Module Signing === | === Module Signing === | ||
On systems with Secure Boot enabled (mine), you most likely need to sign the module. See [https://download.nvidia.com/XFree86/Linux-x86_64/570.153.02/README/installdriver.html#modulesigning Signing NVIDIA Kernel Module]. However, I didn't get an explicit message that signing was a problem; and I did see that the installation process signs the module with a generated key. I assume that the MOK process hooks into the trust system somehow. | On systems with Secure Boot enabled (mine), you most likely need to sign the module. See [https://download.nvidia.com/XFree86/Linux-x86_64/570.153.02/README/installdriver.html#modulesigning Signing NVIDIA Kernel Module]. However, I didn't get an explicit message that signing was a problem; and I did see that the installation process signs the module with a generated key. I assume that the MOK process hooks into the trust system somehow. | ||
When troubleshooting keeps turning up mysteries, you have to check your assumptions.<syntaxhighlight lang="text"> | |||
sudo modprobe nvidia | |||
modprobe: ERROR: could not insert 'nvidia': Key was rejected by service | |||
</syntaxhighlight>See [[Nvidia on Ubuntu/Kernel modules|Kernel modules]] | |||
== Tools and Troubleshooting == | == Tools and Troubleshooting == | ||
| Line 244: | Line 254: | ||
As a regular user, my DE is KDE Plasma (using Kubuntu) rather than the GNOME default of Ubuntu | As a regular user, my DE is KDE Plasma (using Kubuntu) rather than the GNOME default of Ubuntu | ||
{{Subpages|}} | |||
{{ | |||
{{References}} | {{References}} | ||