0

I am working with a RPI4B 2GB, on which I've installed Raspberry OS.

Due to a specific issue, I've had to downgrade my kernel version to 4.19.118-v7l, using sudo rpi-update e1050e94821a70b2e4c72b318d6c6c968552e9a2.

In doing so, I broke my wireguard install, or at least the part of it that relied on the kernel headers. At present, it seems like the kernel is properly downgraded, but I can't manage to install the corresponding kernel headers to get wireguard to work again.

I tried sudo apt-get install raspberrypi-kernel-headers, which results in

Reading package lists... Done
Building dependency tree
Reading state information... Done
raspberrypi-kernel-headers is already the newest version (1.20210303-1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded

sudo apt-get install raspberrypi-kernel-headers-4.19.118-v7l, however, results in

Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package raspberrypi-kernel-headers-4.19.118-v7l
E: Couldn't find any package by glob 'raspberrypi-kernel-headers-4.19.118-v7l'
E: Couldn't find any package by regex 'raspberrypi-kernel-headers-4.19.118-v7l'

apt list linux-headers-* gives a list that does not include the linux headers for 4.19.118-v7l:

linux-headers-4.18.0-3-common-rt/stable 4.18.20-2+rpi1 all
linux-headers-4.18.0-3-common/stable,now 4.18.20-2+rpi1 all [installed]
linux-headers-4.9.0-6-all-armhf/stable 4.9.82-1+deb9u3+rpi2 armhf
linux-headers-4.9.0-6-all/stable 4.9.82-1+deb9u3+rpi2 armhf
linux-headers-4.9.0-6-common-rt/stable 4.9.82-1+deb9u3+rpi2 all
linux-headers-4.9.0-6-common/stable 4.9.82-1+deb9u3+rpi2 all
linux-headers-4.9.0-6-rpi2/stable 4.9.82-1+deb9u3+rpi2 armhf
linux-headers-4.9.0-6-rpi/stable 4.9.82-1+deb9u3+rpi2 armhf
linux-headers-rpi-rpfv/stable 4.9+80+deb9u4+rpi2 armhf
linux-headers-rpi2-rpfv/stable 4.9+80+deb9u4+rpi2 armhf
linux-headers-rpi2/stable 4.9+80+deb9u4+rpi2 armhf
linux-headers-rpi/stable 4.9+80+deb9u4+rpi2 armhf

The only "all" linux-header I get is for kernel v.4.9.0-6. I'm not sure it would be wise to downgrade the kernel that far back just to get the headers... I tried installing linux-headers-4.18.0-3-common/stable but that didn't solve the issue.

I have also tried using rpi-source, but aside from running it with the rpi-source command, I am not sure what to do with it. It didn't solve the issue.

Would anyone have a suggestion to downgrade the kernel headers to match the kernel version currently installed? Thanks!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.