Impossible to build modules

Hello,
I’m having a strange problem, today my webcam didn’t work, it happens from time to time and therefore I tried to rebuild the dkms modules.
This is the output of the command, and of course no external modules were built (I didn’t notice but also bluetooth and wifi weren’t working).

sudo dkms autoinstall --all                                      ✔ 
[sudo] password di aleritty: 

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.

Notice that it seems like the kernel is not recognized.
Of course I have linux612 and linux612-headers installed.
But also linux66 and linux66-headers.

Thinking about some download problem I tried download the linux-ck kernel, with the same result.

Of course the sources are there:

ls -al /usr/lib/modules/                                                                                                     11 ✘  7s  
drwxr-xr-x - root 27 dic  2024 6.6.65-1-MANJARO
drwxr-xr-x - root 22 gen 17:25 6.11.7-1-ck-generic-v3
drwxr-xr-x - root 22 gen 17:16 6.11.11-1-MANJARO
drwxr-xr-x - root 22 gen 17:01 6.12.4-1-MANJARO

So now I have the following situation:

uname -a                                                         ✔ 
Linux Cervello 6.11.7-1-ck-generic-v3 #1 SMP PREEMPT_DYNAMIC Sat Nov  9 12:02:35 EST 2024 x86_64 GNU/Linux
$ sudo dkms autoinstall --all
sudo] password di aleritty: 

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.
Autoinstall on  failed for module(s) binder(1) r8168(1) ryzen_smu(1) v4l2loopback(1).

Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.

$ ls -al /usr/lib/modules/
drwxr-xr-x - root 27 dic  2024 6.6.65-1-MANJARO
drwxr-xr-x - root 22 gen 17:25 6.11.7-1-ck-generic-v3
drwxr-xr-x - root 22 gen 17:16 6.11.11-1-MANJARO
drwxr-xr-x - root 22 gen 17:01 6.12.4-1-MANJARO

What can it be?

Thank you
Best regards

Your output mentions linux11, which is EOL:

I assume you are running this, or still have it installed? To check:

mhwd-kernel -li
1 Like

I’m running linux611-ck which is not EOL.

Currently running: 6.11.7-1-ck-generic-v3 (linux611)
The following kernels are installed in your system:

  • linux611
  • linux612
  • linux66

But the problem persists with any kernel I tried (66, 612 and the current CK), please check the output of dkms because that’s the most strange and relevant.

you issued:

which resulted in:

Did you try to do that?
I mean especially the second part:
or use the --kernelsourcedir option

I’m not too familiar with dkms - but this one kernel is a custom one, not a Manjaro kernel.

This happens also with the manjaro official kernels, I switched to this one because the official kernels didn’t solve the problem, and of coures I have the relevant headers for all of them installed.

sudo pacman -Q | grep headers                                    ✔ 
[sudo] password di aleritty: 
linux-api-headers 6.10-1
linux-ck-generic-v3-headers 6.11.7-1
linux611-headers 6.11.11-1
linux612-headers 6.12.4-1
linux66-headers 6.6.65-1
opencl-headers 2:2024.10.24-1
vulkan-headers 1:1.4.303-1

To me it looks like the whole thing fails because of just one kernel.

… one bad egg spoils the whole thing …

Yes but which one?
I’ll try to remove linux612… just in case…

I’d rather eliminate the non-standard one:

linux-ck-generic-v3-headers

and, of course, any kernel that is no longer supported.

Did you try:

I tried and it get’s completely ignored…
I still get:

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.

Look at this message, it seems like the system is missing the variable containing the kernel version… there is a double // and a double space instead of the kernel version…

I can’t currently uninstall the CK one, because it’s the one I’m running… But I’m trying to build from source again the kernel, so maybe will work…

I saw that.
Can’t interpret it, though.

Your webcam isn’t working … started this?
Does it even need special modules not present with the default kernels?

I cannot help - have only a VM with only standard kernels and no need for dkms.

these where the reasons for failing:

Autoinstall on  failed for module(s) binder(1) r8168(1) ryzen_smu(1) v4l2loopback(1)

Yes, definitely.
The problem is that i noticed the webcam, but also a lot of other things aren’t working in reality…

Now I need to find the reason it is not building and fix it…
But thank you anyway for your help.

Just for completeness:

uname -a                                                         ✔ 
Linux Cervello 6.6.65-1-MANJARO #1 SMP PREEMPT_DYNAMIC Wed Dec 11 22:24:04 UTC 2024 x86_64 GNU/Linux
    ~  sudo dkms autoinstall --all                                      ✔ 
[sudo] password di aleritty: 

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.

Error! Your kernel headers for kernel  cannot be found at /usr/lib/modules//build or /usr/lib/modules//source.
Please install the linux-headers- package or use the --kernelsourcedir option to tell DKMS where it's located.
Autoinstall on  failed for module(s) r8168(1) ryzen_smu(1) v4l2loopback(1).

Error! One or more modules failed to install during autoinstall.
Refer to previous errors for more information.

That is a strange issue …

For comparison - on several systems I have

  • vmware-workstation
  • v4l2loopback-dkms
  • virtualbox-host-dkms

all using dkms - and I have no issues when they are rebuilt due to kernel updates.

So I am speculating if your setup is some kind of manual build of modules?

I cannot help but wondering why you have r8168 as a separate module - that shouldn’t be necessary.

I use the r818-DKMS because it’s not included in the CK kernel, therefore I need to build it.

Manjaro has a kernel module for r8168 but it is mostly obsolete and only provided as a fallback.

The kernel driver for r8169 covers both r8168 and r8169 and should be preferred over the extra module.

  • v4l2loopback-dkms is in Arch and Manjaro extra repo
  • ryzen_smu-dkms is in Manjaro extra repo
  • linuxXY-r8168 is available for Manjaro kernels

So your issue is entirely related to your custom kernel - which is an unsupported configuration.

4 Likes

I’m sorry but I have to disagree.
The issue started when using Linux612 from manjaro.
I posted an output aso from linux66 (which is LTS) now.

So the bluetooth is not working, camera not working and for some reason after logging in I’m left for a long time with a black screen…

And of course that very strange message in DKMS

I cannot find linux612-r8169 anywhere tough.

check your dkms config - you are using a non standard kernel

Arch is using just one kernel - to use two or more some configuration is required
… there is a likely significant difference …
between Manjaro and Arch

I didn’t say it existed.

There is not extra module for r8169 as r8169/r8168 support is part of the kernel.

Historically there has been a need for a separate module r8168 - I know because a Clevo laptop I own worked better with the extra module - but kernel support for r8168/r8169 has improved and it has now been several years since r8168 became obsolete for my system.

Perhaps there still is a need for this separate r8168 module :man_shrugging:

Ok, I’ve repeated this many times now…
The issue started with the STANDARD kernel.
I HAD to switch to the “non standard one”, because the standard one is barely unusable.

No matter how many times you repeat - the issue is not reproducable - thus it is likely a local issue.

Your system is unsuppoted - it is not possible to suggest a meaningful course of action when you are using non Manjaro sources.

You need to clean your system for all foreign packages before this topic can be considered relevant to Manjaro Linux systems.

4 Likes