Can't install Nvidia drivers, akmods missing directory error | F40 | kernel updates

Hi everyone,

I’m having troubles to install nvidia drivers (what a unusual issue ^^').
I fully reinstalled my Nvidia drivers;

dnf list installed nvidia outputs :

akmod-nvidia.x86_64                                                           3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
nvidia-modprobe.x86_64                                                        3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
nvidia-persistenced.x86_64                                                    3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
nvidia-settings.x86_64                                                        3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia.x86_64                                                    3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-cuda.x86_64                                               3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-cuda-libs.i686                                            3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-cuda-libs.x86_64                                          3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-kmodsrc.x86_64                                            3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-libs.i686                                                 3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-libs.x86_64                                               3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-power.x86_64                                              3:550.90.07-1.fc40                                          @rpmfusion-nonfree-nvidia-driver

But sudo akmods outputs this very weird error :

Checking kmods exist for 6.9.7-200.fc40.x86_64             [  OK  ]
Building and installing nvidia-kmod                        [MISLUKT]
Building rpms failed; see /var/cache/akmods/nvidia/550.90.07-1-for-6.9.7-200.fc40.x86_64.failed.log for details
Building and installing v4l2loopback-kmod                  [MISLUKT]
Building rpms failed; see /var/cache/akmods/v4l2loopback/0.13.1-1-for-6.9.7-200.fc40.x86_64.failed.log for details

Hint: Some kmods were ignored or failed to build or install.
You can try to rebuild and install them by by calling
'/usr/sbin/akmods --force' as root.

The log file reports this :

2024/07/03 16:29:42 akmods: Building RPM using the command '/usr/sbin/akmodsbuild --kernels 6.9.7-200.fc40.x86_64 /usr/src/akmods/nvidia-kmod.latest'
ERROR: Files needed for building modules against kernel
 6.9.7-200.fc40.x86_64 could not be found as the following
 directories are missing:
 /usr/src/kernels/6.9.7-200.fc40.x86_64/
 /usr/lib/modules/6.9.7-200.fc40.x86_64/build/
2024/07/03 16:29:42 akmods: Building rpms failed; see /var/cache/akmods/nvidia/550.90.07-1-for-6.9.7-200.fc40.x86_64.failed.log for details

Checking if the kernels are there then… (sudo ls -l /usr/src/kernels/) :

drwxr-xr-x. 1 root root 404  3 jui 15:58 6.8.11-300.fc40.x86_64
drwxr-xr-x. 1 root root 432  3 jui 15:58 6.9.4-200.fc40.x86_64
drwxr-xr-x. 1 root root 432  3 jui 15:58 6.9.5-200.fc40.x86_64
drwxr-xr-x. 1 root root 432  3 jui 15:58 6.9.6-200.fc40.x86_64
drwxr-xr-x. 1 root root 432  3 jui 15:56 6.9.7-200.fc40.x86_64 (so it exists ??)

Same here for the module (sudo ls -l /usr/lib/modules/6.9.7-200.fc40.x86_64/) :

lrwxrwxrwx. 1 root root       38 27 jun 02:00 build -> /usr/src/kernels/6.9.7-200.fc40.x86_64
...

Dnf list reports this (there is a devel for 6.9.7, is the problem is because kernel headers is 6.9.4 ??) :

kernel.x86_64                                                                         6.9.7-200.fc40                                                        @updates    
kernel-core.x86_64                                                                    6.9.7-200.fc40                                                        @updates      
kernel-devel.x86_64                                                                   6.9.7-200.fc40                                                        @updates      
kernel-devel-matched.x86_64                                                           6.9.7-200.fc40                                                        @updates      
kernel-headers.x86_64                                                                 6.9.4-200.fc40                                                        @updates      
kernel-modules.x86_64                                                                 6.9.7-200.fc40                                                        @updates    
kernel-modules-core.x86_64                                                            6.9.7-200.fc40                                                        @updates      
kernel-modules-extra.x86_64                                                           6.9.7-200.fc40                                                        @updates      
kernel-srpm-macros.noarch                                                             1.0-23.fc40                                                           @fedora       
kernel-tools.x86_64                                                                   6.9.7-200.fc40                                                        @updates      
kernel-tools-libs.x86_64                                                              6.9.7-200.fc40                                                        @updates      
libreport-plugin-kerneloops.x86_64                                                    2.17.15-1.fc40                                                        @fedora       
...

Soooo… I’m completely lost, why would akmods-nvidia says that directories are missing while they exists… Any help is appreciated ty !

(NB: Secure boot is enabled, and i followed HowTo/SecureBoot to sign with mokutils)

A wild guess, maybe a selinux issue?
You could try the selinux auto relable and see if that makes a difference.

No, that is expected.

Thank you for your help !
Yes, indeed my SELinux policy is set to enforced, I just relabeled my entire fs and it didn’t work :confused: I checked the logs and it seems that it is “unconfined” (so not affected, i suppose?)

type=CRED_ACQ msg=audit(1720020989.109:266): pid=13829 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_rootok acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'UID="root" AUID="H-C"
type=USER_START msg=audit(1720020989.113:267): pid=13829 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_unix acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'UID="root" AUID="H-C"
type=USER_END msg=audit(1720020989.125:268): pid=13829 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_unix acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'UID="root" AUID="H-C"
type=CRED_DISP msg=audit(1720020989.125:269): pid=13829 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_rootok acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'UID="root" AUID="H-C"

It makes me think that I edited a lot of settings to harden my linux system : grub boot settings, sysctl.conf, crypto policy set to FUTURE (while still accepting 2048bits keys) and so on.
Might it be related ?

try sudo dnf distro-sync --refresh then try the sudo akmods --force command to see if it will build the module that time.

I just installed kernel 6.9.7 and it built the modules properly.

I do note though that you are missing the nvidia-gpu-firmware package which really must be installed. sudo dnf install nvidia-gpu-firmware

This seems to indicate that you may have used dnf remove \*nvidia\* to remove the drivers and it should have been dnf remove \*nvidia\* --exclude nvidia-gpu-firmware

1 Like

Thank you for your help :slight_smile: !

I’ve just applied what you said, it didn’t work too :frowning_with_open_mouth: :
sudo dnf distro-sync --refresh just reported “Nothing to do”

I also rebooted and retried but unfortunately I still have the exact same error.
sudo dnf list \*nvidia\* reports now this :

akmod-nvidia.x86_64                                                                                              3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
nvidia-gpu-firmware.noarch                                                                                       20240610-1.fc40                                                                            @updates                        
nvidia-modprobe.x86_64                                                                                           3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
nvidia-persistenced.x86_64                                                                                       3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
nvidia-settings.x86_64                                                                                           3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia.x86_64                                                                                       3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-cuda.x86_64                                                                                  3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-cuda-libs.i686                                                                               3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-cuda-libs.x86_64                                                                             3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-kmodsrc.x86_64                                                                               3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-libs.i686                                                                                    3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-libs.x86_64                                                                                  3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver
xorg-x11-drv-nvidia-power.x86_64                                                                                 3:550.90.07-1.fc40                                                                         @rpmfusion-nonfree-nvidia-driver

I’m being clueless about this and I found no topics having a similar issue than me, I’m really confused to be honest!

Welcome to :fedora:

:thinking: Don’t you need the devel packages + headers for all kernels installed?

Thank you ! (NB: I use fedora since a year now, and I must that I love it :))

Concerning what you said, I’ve put … for the olders kernels to avoid to overflow my initial message.
Here is the full list of sudo dnf list \*kernel*\:

abrt-addon-kerneloops.x86_64                                                                                           2.17.5-1.fc40                                                                                          @fedora       
kernel.x86_64                                                                                                          6.8.11-300.fc40                                                                                        @updates      
kernel.x86_64                                                                                                          6.9.4-200.fc40                                                                                         @updates      
kernel.x86_64                                                                                                          6.9.5-200.fc40                                                                                         @updates      
kernel.x86_64                                                                                                          6.9.6-200.fc40                                                                                         @updates      
kernel.x86_64                                                                                                          6.9.7-200.fc40                                                                                         @updates      
kernel-core.x86_64                                                                                                     6.8.11-300.fc40                                                                                        @updates      
kernel-core.x86_64                                                                                                     6.9.4-200.fc40                                                                                         @updates      
kernel-core.x86_64                                                                                                     6.9.5-200.fc40                                                                                         @updates      
kernel-core.x86_64                                                                                                     6.9.6-200.fc40                                                                                         @updates      
kernel-core.x86_64                                                                                                     6.9.7-200.fc40                                                                                         @updates      
kernel-devel.x86_64                                                                                                    6.8.11-300.fc40                                                                                        @updates      
kernel-devel.x86_64                                                                                                    6.9.4-200.fc40                                                                                         @updates      
kernel-devel.x86_64                                                                                                    6.9.5-200.fc40                                                                                         @updates      
kernel-devel.x86_64                                                                                                    6.9.6-200.fc40                                                                                         @updates      
kernel-devel.x86_64                                                                                                    6.9.7-200.fc40                                                                                         @updates      
kernel-devel-matched.x86_64                                                                                            6.9.7-200.fc40                                                                                         @updates      
kernel-headers.x86_64                                                                                                  6.9.4-200.fc40                                                                                         @updates      
kernel-modules.x86_64                                                                                                  6.8.11-300.fc40                                                                                        @updates      
kernel-modules.x86_64                                                                                                  6.9.4-200.fc40                                                                                         @updates      
kernel-modules.x86_64                                                                                                  6.9.5-200.fc40                                                                                         @updates      
kernel-modules.x86_64                                                                                                  6.9.6-200.fc40                                                                                         @updates      
kernel-modules.x86_64                                                                                                  6.9.7-200.fc40                                                                                         @updates      
kernel-modules-core.x86_64                                                                                             6.8.11-300.fc40                                                                                        @updates      
kernel-modules-core.x86_64                                                                                             6.9.4-200.fc40                                                                                         @updates      
kernel-modules-core.x86_64                                                                                             6.9.5-200.fc40                                                                                         @updates      
kernel-modules-core.x86_64                                                                                             6.9.6-200.fc40                                                                                         @updates      
kernel-modules-core.x86_64                                                                                             6.9.7-200.fc40                                                                                         @updates      
kernel-modules-extra.x86_64                                                                                            6.8.11-300.fc40                                                                                        @updates      
kernel-modules-extra.x86_64                                                                                            6.9.4-200.fc40                                                                                         @updates      
kernel-modules-extra.x86_64                                                                                            6.9.5-200.fc40                                                                                         @updates      
kernel-modules-extra.x86_64                                                                                            6.9.6-200.fc40                                                                                         @updates      
kernel-modules-extra.x86_64                                                                                            6.9.7-200.fc40                                                                                         @updates      
kernel-srpm-macros.noarch                                                                                              1.0-23.fc40                                                                                            @fedora       
kernel-tools.x86_64                                                                                                    6.9.7-200.fc40                                                                                         @updates      
kernel-tools-libs.x86_64                                                                                               6.9.7-200.fc40                                                                                         @updates      
libreport-plugin-kerneloops.x86_64                                                                                     2.17.15-1.fc40                                                                                         @fedora     

That message shows the log file that may show the cause.
Please try cat /var/cache/akmods/nvidia/550.90.07-1-for-6.9.7-200.fc40.x86_64.failed.log | fpaste and post the resultant url here so we can see the content of that log. I suspect the same error also resides in the log for v4l2loopback as well.

Did you run akmods as suggested in that error message?
You can try to rebuild and install them by by calling '/usr/sbin/akmods --force' as root.

Here it is! UNTITLED - Pastebin Service

v4l2loopback log file reports the same error.

I also tried the command /usr/sbin/akmods --force (as root and by using sudo) and in fact it executes the same command.

I am not sure why you would have 5 different kernels installed. Fedora by default only keeps the last 3.

Is there a reason you may have altered the entry in /etc/dnf/dnf.conf to keep additional kernels?

Your command would show all kernels, including the one with the first release of f40 and the latest available in updates if not already installed, not just the ones currently installed. Changing it to read sudo dnf list installed kernel\* would show only the currently installed kernels.

Oh yes! I remember that I tweaked it cause the name “installonly_limit” was confusing (I thought it was how many packets could be installed at the same time, so I wanted faster), but it is indeed not what I thought ^^’ I’ve just reverted my settings, as there were no particular reason and even went in trouble just before updating the kernel due to lack of space in /boot

sudo dnf list installed kernel\* outputs this (I haven’t removed 4th-5th older kernels yet) :

Geïnstalleerde pakketten
kernel.x86_64                                                                                                           6.8.11-300.fc40                                                                                             @updates
kernel.x86_64                                                                                                           6.9.4-200.fc40                                                                                              @updates
kernel.x86_64                                                                                                           6.9.5-200.fc40                                                                                              @updates
kernel.x86_64                                                                                                           6.9.6-200.fc40                                                                                              @updates
kernel.x86_64                                                                                                           6.9.7-200.fc40                                                                                              @updates
kernel-core.x86_64                                                                                                      6.8.11-300.fc40                                                                                             @updates
kernel-core.x86_64                                                                                                      6.9.4-200.fc40                                                                                              @updates
kernel-core.x86_64                                                                                                      6.9.5-200.fc40                                                                                              @updates
kernel-core.x86_64                                                                                                      6.9.6-200.fc40                                                                                              @updates
kernel-core.x86_64                                                                                                      6.9.7-200.fc40                                                                                              @updates
kernel-devel.x86_64                                                                                                     6.8.11-300.fc40                                                                                             @updates
kernel-devel.x86_64                                                                                                     6.9.4-200.fc40                                                                                              @updates
kernel-devel.x86_64                                                                                                     6.9.5-200.fc40                                                                                              @updates
kernel-devel.x86_64                                                                                                     6.9.6-200.fc40                                                                                              @updates
kernel-devel.x86_64                                                                                                     6.9.7-200.fc40                                                                                              @updates
kernel-devel-matched.x86_64                                                                                             6.9.7-200.fc40                                                                                              @updates
kernel-headers.x86_64                                                                                                   6.9.4-200.fc40                                                                                              @updates
kernel-modules.x86_64                                                                                                   6.8.11-300.fc40                                                                                             @updates
kernel-modules.x86_64                                                                                                   6.9.4-200.fc40                                                                                              @updates
kernel-modules.x86_64                                                                                                   6.9.5-200.fc40                                                                                              @updates
kernel-modules.x86_64                                                                                                   6.9.6-200.fc40                                                                                              @updates
kernel-modules.x86_64                                                                                                   6.9.7-200.fc40                                                                                              @updates
kernel-modules-core.x86_64                                                                                              6.8.11-300.fc40                                                                                             @updates
kernel-modules-core.x86_64                                                                                              6.9.4-200.fc40                                                                                              @updates
kernel-modules-core.x86_64                                                                                              6.9.5-200.fc40                                                                                              @updates
kernel-modules-core.x86_64                                                                                              6.9.6-200.fc40                                                                                              @updates
kernel-modules-core.x86_64                                                                                              6.9.7-200.fc40                                                                                              @updates
kernel-modules-extra.x86_64                                                                                             6.8.11-300.fc40                                                                                             @updates
kernel-modules-extra.x86_64                                                                                             6.9.4-200.fc40                                                                                              @updates
kernel-modules-extra.x86_64                                                                                             6.9.5-200.fc40                                                                                              @updates
kernel-modules-extra.x86_64                                                                                             6.9.6-200.fc40                                                                                              @updates
kernel-modules-extra.x86_64                                                                                             6.9.7-200.fc40                                                                                              @updates
kernel-srpm-macros.noarch                                                                                               1.0-23.fc40                                                                                                 @fedora 
kernel-tools.x86_64                                                                                                     6.9.7-200.fc40                                                                                              @updates
kernel-tools-libs.x86_64                                                                                                6.9.7-200.fc40                                                                                              @updates

That error log is extremely short and shows this.

2024/07/03 18:01:20 akmods: Building RPM using the command '/usr/sbin/akmodsbuild --kernels 6.9.7-200.fc40.x86_64 /usr/src/akmods/nvidia-kmod.latest'
ERROR: Files needed for building modules against kernel
 6.9.7-200.fc40.x86_64 could not be found as the following
 directories are missing:
 /usr/src/kernels/6.9.7-200.fc40.x86_64/
 /usr/lib/modules/6.9.7-200.fc40.x86_64/build/
2024/07/03 18:01:20 akmods: Building rpms failed; see /var/cache/akmods/nvidia/550.90.07-1-for-6.9.7-200.fc40.x86_64.failed.log for details

Those 2 missing directories should be provided by the kernel-devel package for the 6.9.7 kernel (the second is a link to the first)
Running ls /usr/src/kernels/ should show if the directory exists or not. If it does not then the command sudo dnf reinstall kernel\* should reinstall all the kernel packages for the 6.9.7 kernel and may solve the error.

My best suggestion is:
If I were to need that I actually would run sudo dnf remove kernel\*6.9.7\* and after that completed would run sudo dnf upgrade --refresh to reinstall that kernel and all related updates. Doing so would automatically also rebuild those kernel modules as long as you waited at least 5 minutes after the update completed before rebooting.

1 Like

The files did existed but I’ve reinstalled my kernel in case.
Andd… I still have the same error even if the files exists :frowning:

And yes, indeed the error log is extremely short, and, a priori, there is no verbose mode to akmods, which is a pity…

I’m sure there’s a solution, just don’t what could be the problem ^^’
But thank you for helping me in any case!

Can you provide the output of journalctl -xe | fpaste --raw-url for us? Since you said you :

  • Removed the kernel and reinstalled
  • Did a dnf update
  • waited for modules to rebuild and rebooted (I think with akmods, there some stuff happening during the reboot? not sure. . . )
  • So since you rebooted there should be some extensive logs here to read.

journalctl -xe | fpaste --raw-url produced this output : https://paste.centos.org/view/raw/2fc95e45

I directly copied here what might interest you (the rest seems to be a lot of spam and rnd shit error from my computer) :

jui 03 19:27:59 home audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=fprintd comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
jui 03 19:28:03 home audit[18291]: USER_AUTH pid=18291 uid=1000 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:authentication grantors=pam_usertype,pam_localuser,pam_unix acct="H-C" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/1 res=success'
jui 03 19:28:03 home audit[18291]: USER_ACCT pid=18291 uid=1000 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:accounting grantors=pam_unix,pam_localuser acct="H-C" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/1 res=success'
jui 03 19:28:03 home sudo[18291]:      H-C : TTY=pts/1 ; PWD=/home/H-C ; USER=root ; COMMAND=/usr/sbin/akmods --force
jui 03 19:28:03 home audit[18291]: USER_CMD pid=18291 uid=1000 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='cwd="/home/H-C" cmd=616B6D6F6473202D2D666F726365 exe="/usr/bin/sudo" terminal=pts/1 res=success'
jui 03 19:28:03 home audit[18291]: CRED_REFR pid=18291 uid=1000 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_localuser,pam_unix acct="root" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/1 res=success'
jui 03 19:28:03 home sudo[18291]: pam_unix(sudo:session): session opened for user root(uid=0) by H-C(uid=1000)
jui 03 19:28:03 home audit[18291]: USER_START pid=18291 uid=1000 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_keyinit,pam_limits,pam_systemd,pam_unix acct="root" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/1 res=success'
jui 03 19:28:03 home audit[18574]: CRED_ACQ pid=18574 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_rootok acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:03 home runuser[18574]: pam_unix(runuser:session): session opened for user akmods(uid=981) by H-C(uid=0)
jui 03 19:28:03 home audit[18574]: USER_START pid=18574 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_unix acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:03 home runuser[18574]: pam_unix(runuser:session): session closed for user akmods
jui 03 19:28:03 home audit[18574]: USER_END pid=18574 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_unix acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:03 home audit[18574]: CRED_DISP pid=18574 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_rootok acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:03 home audit[18600]: CRED_ACQ pid=18600 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_rootok acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:03 home runuser[18600]: pam_unix(runuser:session): session opened for user akmods(uid=981) by H-C(uid=0)
jui 03 19:28:03 home audit[18600]: USER_START pid=18600 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_open grantors=pam_keyinit,pam_limits,pam_unix acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:03 home runuser[18600]: pam_unix(runuser:session): session closed for user akmods
jui 03 19:28:03 home audit[18600]: USER_END pid=18600 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_unix acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:03 home audit[18600]: CRED_DISP pid=18600 uid=0 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_rootok acct="akmods" exe="/usr/sbin/runuser" hostname=? addr=? terminal=/dev/pts/2 res=success'
jui 03 19:28:05 home sudo[18291]: pam_unix(sudo:session): session closed for user root
jui 03 19:28:05 home audit[18291]: USER_END pid=18291 uid=1000 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:session_close grantors=pam_keyinit,pam_limits,pam_keyinit,pam_limits,pam_systemd,pam_unix acct="root" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/1 res=success'
jui 03 19:28:05 home audit[18291]: CRED_DISP pid=18291 uid=1000 auid=1000 ses=3 subj=unconfined_u:unconfined_r:unconfined_t:s0-s0:c0.c1023 msg='op=PAM:setcred grantors=pam_localuser,pam_unix acct="root" exe="/usr/bin/sudo" hostname=? addr=? terminal=/dev/pts/1 res=success'

Just wonder, did you also check /usr/src/kernels/6.9.7-200.fc40.x86_64? That is what is claimed to be missing.

Yes indeed! It exists as ls -l /usr/src/kernels/6.9.7-200.fc40.x86_64 outputs the content of the kernel :

totaal 14052
drwxr-xr-x. 1 root root     228  3 jui 18:57 arch
drwxr-xr-x. 1 root root      80  3 jui 18:57 block
drwxr-xr-x. 1 root root      30  3 jui 18:57 certs
drwxr-xr-x. 1 root root      76  3 jui 18:57 crypto
drwxr-xr-x. 1 root root      98  3 jui 18:57 Documentation
drwxr-xr-x. 1 root root    1436  3 jui 18:57 drivers
drwxr-xr-x. 1 root root     884  3 jui 18:57 fs
drwxr-xr-x. 1 root root     322 27 jun 02:00 include
drwxr-xr-x. 1 root root      30  3 jui 18:58 init
drwxr-xr-x. 1 root root      16  3 jui 18:58 io_uring
drwxr-xr-x. 1 root root      16  3 jui 18:58 ipc
-rw-r--r--. 3 root root     580 27 jun 02:00 Kconfig
-rw-r--r--. 3 root root     393 27 jun 02:00 Kconfig.redhat
drwxr-xr-x. 1 root root     338  3 jui 18:58 kernel
drwxr-xr-x. 1 root root     412  3 jui 18:58 lib
-rw-r--r--. 1 root root   68020 27 jun 02:00 Makefile
-rw-r--r--. 3 root root    2642 27 jun 02:00 Makefile.rhelver
drwxr-xr-x. 1 root root      98  3 jui 18:58 mm
-rw-r--r--. 1 root root 1870383 27 jun 02:00 Module.symvers
drwxr-xr-x. 1 root root     808  3 jui 18:58 net
drwxr-xr-x. 1 root root      16  3 jui 18:58 rust
drwxr-xr-x. 1 root root     570  3 jui 18:58 samples
drwxr-xr-x. 1 root root    4642  3 jui 18:58 scripts
drwxr-xr-x. 1 root root     220  3 jui 18:58 security
drwxr-xr-x. 1 root root     232  3 jui 18:58 sound
-rw-r--r--. 1 root root 9261257 27 jun 02:00 System.map
drwxr-xr-x. 1 root root     390  3 jui 18:58 tools
drwxr-xr-x. 1 root root      44  3 jui 18:58 usr
drwxr-xr-x. 1 root root      28  3 jui 18:58 virt
-rw-r--r--. 1 root root 3163457 27 jun 02:00 vmlinux.h
-rw-r--r--. 1 root root      41 27 jun 02:00 vmlinux.id

Headers only changes if the actual headers change. THere is a -devel for each kernel.
For example this is my setup of kernel RPMs that can build akmods-nvidia.

$ dnf list installed *kernel*
Installed Packages
abrt-addon-kerneloops.x86_64                                      2.17.5-1.fc40                                 @fedora
kernel-core.x86_64                                                6.9.5-200.fc40                                @updates
kernel-core.x86_64                                                6.9.6-200.fc40                                @updates
kernel-core.x86_64                                                6.9.7-200.fc40                                @updates
kernel-devel.x86_64                                               6.9.5-200.fc40                                @updates
kernel-devel.x86_64                                               6.9.6-200.fc40                                @updates
kernel-devel.x86_64                                               6.9.7-200.fc40                                @updates
kernel-devel-matched.x86_64                                       6.9.7-200.fc40                                @updates
kernel-headers.x86_64                                             6.9.4-200.fc40                                @updates
kernel-modules.x86_64                                             6.9.5-200.fc40                                @updates
kernel-modules.x86_64                                             6.9.6-200.fc40                                @updates
kernel-modules.x86_64                                             6.9.7-200.fc40                                @updates
kernel-modules-core.x86_64                                        6.9.5-200.fc40                                @updates
kernel-modules-core.x86_64                                        6.9.6-200.fc40                                @updates
kernel-modules-core.x86_64                                        6.9.7-200.fc40                                @updates
kernel-modules-extra.x86_64                                       6.9.5-200.fc40                                @updates
kernel-modules-extra.x86_64                                       6.9.6-200.fc40                                @updates
kernel-modules-extra.x86_64                                       6.9.7-200.fc40                                @updates
kernel-srpm-macros.noarch                                         1.0-23.fc40                                   @fedora
1 Like

For SELinux issues you need to look for lines containing “AVC” in the journal.

The “unconfined_t” is just a label and doesn’t tell anything about the state of SELinux.

1 Like