0

Running on a Raspberry Pi 4 Model B, Raspberry Pi OS 64 Lite

Error:

$ sudo apt-get install raspberrypi-kernel-headers
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package raspberrypi-kernel-headers

Kernel:

$ uname -a
Linux test-rpi 6.1.55-v8+ #1686 SMP PREEMPT Thu Oct  5 15:47:38 BST 2023 aarch64 GNU/Linux

Sources:

$ cat /etc/apt/sources.list.d/raspi.list
deb http://archive.raspberrypi.com/debian/ bookworm main
# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://archive.raspberrypi.com/debian/ bookworm main

More tests:

$ apt policy raspberrypi-kernel-headers
N: Unable to locate package raspberrypi-kernel-headers

2 Answers 2

1

Now it's working, I guess there was some maintenance going on. If you know the reason that package wasn't available this morning please share :)

1
  • It happens quite often and thats the reason I have started to use apt list <pkg name> to rule out spelling errors, one possible fault ruled out.
    – MatsK
    Oct 12, 2023 at 9:27
-1

To verify if a package exists or not in a repository, use:

apt list raspberrypi-kernel-headers

apt list accepts wildcards, ex:

apt list raspberrypi*
2
  • Thank you for your answer. No, apt-get is not deprecated. No, running apt does not help. Please, revisit apt policy documentation.
    – Sanjo
    Oct 11, 2023 at 14:41
  • Thx for your correction.
    – MatsK
    Oct 12, 2023 at 7:08

Not the answer you're looking for? Browse other questions tagged or ask your own question.