Hi all,
I know this subject has been done to death, but previous threads haven’t helped.
I have disabled Secure Boot, but I have an Asus motherboard that only disables secure boot via deleting the keys. I have done so.
I have done dnf reinstall --refresh on all akmod-nvidia related packages, as well as kernel and kernel headers. I have not been able to install the kernel keys to the BIOS.
Terminal outputs :
$ modinfo -F version nvidia
modinfo: ERROR: Module nvidia not found.
$ sudo modprobe nvidia
modprobe: FATAL: Module nvidia not found in directory /lib/modules/5.18.17-200.fc36.x86_64
$ sudo akmods --force
nvidia kernel module missing falling back to nouveau
journalctl -b -u akmods
Aug 17 22:53:50 fedora systemd[1]: Starting akmods.service - Builds and install new kmods from akmod packages...
Aug 17 22:54:59 fedora.home akmods[860]: Checking kmods exist for 5.18.17-200.fc36.x86_64[ OK ]
Aug 17 22:54:59 fedora.home systemd[1]: Finished akmods.service - Builds and install new kmods from akmod packages.
for nvidia :
$ journalctl -b | grep nvidia
Aug 18 00:53:14 fedora kernel: Command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 18 00:53:14 fedora kernel: Kernel command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 18 00:53:14 fedora dracut-cmdline[344]: Using kernel command line parameters: rd.driver.pre=btrfs BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 17 22:54:59 fedora.home systemd[1]: Starting nvidia-fallback.service - Fallback to nouveau as nvidia did not load...
Aug 17 22:55:00 fedora.home systemd[1]: Finished nvidia-fallback.service - Fallback to nouveau as nvidia did not load.
Aug 17 22:55:00 fedora.home audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nvidia-fallback comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Aug 17 22:55:02 fedora.home /usr/libexec/gdm-x-session[1343]: Kernel command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 17 22:55:03 fedora.home /usr/libexec/gdm-x-session[1343]: (II) LoadModule: "glxservernvidia"
Aug 17 22:55:03 fedora.home /usr/libexec/gdm-x-session[1343]: (WW) Warning, couldn't open module glxservernvidia
Aug 17 22:55:03 fedora.home /usr/libexec/gdm-x-session[1343]: (EE) Failed to load module "glxservernvidia" (module does not exist, 0)
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: Kernel command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: (II) LoadModule: "glxservernvidia"
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: (WW) Warning, couldn't open module glxservernvidia
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: (EE) Failed to load module "glxservernvidia" (module does not exist, 0)
Aug 17 22:55:54 fedora.home systemd[1764]: Starting app-nvidia\x2dsettings\x2duser@autostart.service - nvidia-settings...
Aug 17 22:55:55 fedora.home systemd[1764]: Started app-nvidia\x2dsettings\x2duser@autostart.service - nvidia-settings.
Aug 17 22:56:00 fedora.home nvidia-settings[2070]: Locale not supported by C library.
Aug 17 22:56:04 fedora.home nvidia-settings[2070]: ERROR: NVIDIA driver is not loaded
Aug 17 22:56:04 fedora.home systemd[1764]: app-nvidia\x2dsettings\x2duser@autostart.service: Main process exited, code=exited, status=1/FAILURE
Aug 17 22:56:04 fedora.home systemd[1764]: app-nvidia\x2dsettings\x2duser@autostart.service: Failed with result 'exit-code'.
$ journalctl -b -u akmods
Aug 17 22:53:50 fedora systemd[1]: Starting akmods.service - Builds and install new kmods from akmod packages...
Aug 17 22:54:59 fedora.home akmods[860]: Checking kmods exist for 5.18.17-200.fc36.x86_64[ OK ]
Aug 17 22:54:59 fedora.home systemd[1]: Finished akmods.service - Builds and install new kmods from akmod packages.
$ journalctl -b | grep nvidia
Aug 18 00:53:14 fedora kernel: Command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 18 00:53:14 fedora kernel: Kernel command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 18 00:53:14 fedora dracut-cmdline[344]: Using kernel command line parameters: rd.driver.pre=btrfs BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 17 22:54:59 fedora.home systemd[1]: Starting nvidia-fallback.service - Fallback to nouveau as nvidia did not load...
Aug 17 22:55:00 fedora.home systemd[1]: Finished nvidia-fallback.service - Fallback to nouveau as nvidia did not load.
Aug 17 22:55:00 fedora.home audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=nvidia-fallback comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
Aug 17 22:55:02 fedora.home /usr/libexec/gdm-x-session[1343]: Kernel command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 17 22:55:03 fedora.home /usr/libexec/gdm-x-session[1343]: (II) LoadModule: "glxservernvidia"
Aug 17 22:55:03 fedora.home /usr/libexec/gdm-x-session[1343]: (WW) Warning, couldn't open module glxservernvidia
Aug 17 22:55:03 fedora.home /usr/libexec/gdm-x-session[1343]: (EE) Failed to load module "glxservernvidia" (module does not exist, 0)
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: Kernel command line: BOOT_IMAGE=(hd1,gpt2)/vmlinuz-5.18.17-200.fc36.x86_64 root=UUID=ad7ffc57-b243-4b26-8d2e-4356ee0cf874 ro rootflags=subvol=root rhgb quiet rd.driver.blacklist=nouveau modprobe.blacklist=nouveau initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: (II) LoadModule: "glxservernvidia"
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: (WW) Warning, couldn't open module glxservernvidia
Aug 17 22:55:37 fedora.home /usr/libexec/gdm-x-session[1810]: (EE) Failed to load module "glxservernvidia" (module does not exist, 0)
Aug 17 22:55:54 fedora.home systemd[1764]: Starting app-nvidia\x2dsettings\x2duser@autostart.service - nvidia-settings...
Aug 17 22:55:55 fedora.home systemd[1764]: Started app-nvidia\x2dsettings\x2duser@autostart.service - nvidia-settings.
Aug 17 22:56:00 fedora.home nvidia-settings[2070]: Locale not supported by C library.
Aug 17 22:56:04 fedora.home nvidia-settings[2070]: ERROR: NVIDIA driver is not loaded
Aug 17 22:56:04 fedora.home systemd[1764]: app-nvidia\x2dsettings\x2duser@autostart.service: Main process exited, code=exited, status=1/FAILURE
Aug 17 22:56:04 fedora.home systemd[1764]: app-nvidia\x2dsettings\x2duser@autostart.service: Failed with result 'exit-code'.
Hmmm, I see in the OP that you disabled secureboot but given that the module successfully built, this still somehow smells like a secureboot issue. What is the output of sudo mokutil --sb-state ?
I’ve never seen “Platform is in Setup Mode” before, but a quick Google search suggests that it means there are pending certificates. I don’t think that should cause this.
What errors do you get when you try sudo modprobe nvidia manually?
$ sudo dnf install akmod-nvidia
Last metadata expiration check: 1:08:56 ago on Wed Aug 17 23:08:44 2022.
Package akmod-nvidia-3:515.65.01-1.fc36.x86_64 is already installed.
Dependencies resolved.
Nothing to do.
Complete!
Aug 17 22:53:50 fedora systemd[1]: Starting akmods.service - Builds and install new kmods from akmod packages...
Aug 17 22:54:59 fedora.home akmods[860]: Checking kmods exist for 5.18.17-200.fc36.x86_64[ OK ]
Aug 17 22:54:59 fedora.home systemd[1]: Finished akmods.service - Builds and install new kmods from akmod packages.
But modprobe nvidia suggests that it isn’t. What’s the output of find /lib/modules/5.18.17-200.fc36.x86_64 -type f -name "*nvidia*"?
Ok, so it exists, which means we can rule out kmod/akmod being the issue. Now, we just need to figure out why modprobe can’t grok it and… I don’t have any immediate ideas.
$ sudo modprobe -v /lib/modules/5.18.17-200.fc36.x86_64/extra/nvidia/nvidia.ko.xz
modprobe: FATAL: Module /lib/modules/5.18.17-200.fc36.x86_64/extra/nvidia/nvidia.ko.xz not found in directory /lib/modules/5.18.17-200.fc36.x86_64
This error makes sense. Modprobe expects the module name and it searches for it in the kernel path. It’s parsing your fullpath as a module name. I don’t know anything about nvidia-modprobe. Maybe it’s useful?
I am assuming that you installed akmod-nvidia from rpmfusion, but lets find out please.
Post the output of dnf list installed *nvidia* as well as dnf repolist
There have been instances of things not properly compiling the modules and sometimes the fix has been a complete new install of the packages. There have also been instances of some packages installed from rpmfusion-nonfree and some from rpmfusion-nonfree-nvidia-driver which caused interference as well.
The removal and reinstall has been done by having the rpmfusion-nonfree-nvidia-driver repo enabled then using these steps.
dnf remove *nvidia*
followed by
dnf install akmod-nvidia xorg-x11-drv-nvidia-cuda
If this step shows packages to be downloaded from 2 different repos then other steps may need to be taken to install from only one repo. Let us know before you complete this install if it is pulling from more than one repo.
Once the install is complete then wait 2 - 5 minutes and reboot.
Verify the nvidia modules are loaded with lsmod | grep nvidia
If that produces several lines of output then the result is that the nvidia drivers are now properly loaded and functioning.
akmod-nvidia is a tool that builds the needed modules, which are then seen as kmod-nvidia. Removing akmod-nvidia does not remove kmod-nvidia, thus the actual defective modules are still there and do not get rebuilt when akmod-nvidia is reinstalled.