How do I update my kernel header?

I am trying to install the driver for an AC1300 wifi adaptor and I’m following this tutorial

It recommends that :

The linux-headers must also be installed for any DKMS driver version to function. You must install the required linuxXXX-headers package before installing any DKMS driver. You can use the command below to install the headers for all currently installed kernels.

sudo pacman -S $(pacman -Qsq "^linux" | grep "^linux[0-9]*[-rt]*$" | awk '{print $1"-headers"}' ORS=' ') 

When I run this command I get the result:

warning: linux414-headers-4.14.255-1 is up to date – reinstalling
error: target not found: linux59-headers

If I run

mhwd-kernel -li

The output is

The following kernels are installed in your system:

  • linux414
  • linux59

So, how do I find the header for linux59?

Old, unsupported kernel, same as I described moment ago here :slight_smile:

1 Like

can you provide

inxi -Fza

you can add

sudo mhwd-kernel -i linux510
sudo mhwd-kernel -i linux54
sudo mhwd-kernel -i linux515

after reboot you can remove version 5.9

Thank you

I deleted linux59 using the command

sudo mhwd-kernel -r linux59

There were no headers or extramodules

An ancillary question if I may

How come we get stuck with old unsupported kernels? I have never selected a kernel, nor been aware that it needed updating

The update announcement thread always has information about currently supported kernels and kernels which have gone EOL.

For example, the most recent stable announcement:

You should read update announcements, where always is list of currently supported kernels. In new installations is app which notify you about announcements on forum. You also should have notifications from mhwd about new kernels if you didn’t disable them. In my opinion it’s rather hard to stuck in old kernel if you’re aware user.

To some degree, while manjaro tries to make a lot of things easier, administering the system and/or understanding it is still the users responsibility.
Depending on what ISO you installed and how you have configured it you may never get any notification that you should perform any updates or select your graphics card driver … but you still should.
In the case of kernels it is the same … to some extent the user should be expected to understand and manage these (guides, resources, wikis available) … and quite likely, such as in the case of the official flagship ‘full’ editions, a utility called manjaro-settings-manager-notifier will notify you of new kernels, and can be configured as to what notifications you receive under what circumstances as well.

For more information on manjaro kernels and how they are managed see this:
https://wiki.manjaro.org/index.php/Manjaro_Kernels

For a more general overview of kernels and their current state (upstream) see:
kernel.org

AUR packages are created for Arch Linux.

Manjaro supports multiple kernels - Arch only suppors one.

This means Manjaro has multiple headers packages and they use a different name schema - yet providing the required dependency to dkms linux-headers

The kernel dependency must be resolved manually - and you nned to know which kernel you are using - otherwise pacman defaults to the first header package listed linux414-headers which of course won’t work unless you actually are using 4.14 ad the primary kernel.

Manjaro builds upon Arch where the philisophy is K.I.S.S and therefore kernel and kernel headers are split packages.

Only a subset of users wil ever require the linuxXYY-headers package and therefore it is not installed by default and those needed the headers are required to know why and for which kernel.

Adding the linuxXYY-headers package to the default ISO will usually trigger the word bloat with the majority user base.