Caner Taşan
Caner Taşan

Reputation: 71

Unable to locate package linux-headers-4.15.0-kali2-amd64

I try to run apt-get install linux-headers-$(uname -r) But i get an error.

E: Unable to locate package linux-headers-4.15.0-kali2-amd64
E: Couldnt find any package by glob 'linux-headers-4.15.0-kali2-amd64
E: Couldnt find any package by regex'linux-headers-4.15.0-kali2-amd64

So here is the thing, i change source.list with (https://docs.kali.org/general-use/kali-linux-sources-list-repositories) these repositories(the links). I think my version of kali is doesnt match with the links. When i write apt-cache search linux-headers , my headers seems as linux-headers-4.16.0-kali2-all...

So is there any suggestion? How can i solve this problem ? Or is there any link for the 4.16.0 version?

Upvotes: 6

Views: 24132

Answers (3)

Tomer
Tomer

Reputation: 3297

I was able to upgrade to the latest kali version (4.17.0) by running this command:

sudo apt-get install --reinstall linux-image-4.17.0-kali3-amd64

Upvotes: 1

thev0id
thev0id

Reputation: 195

I had the same problem with kali, and got it working by updating linux-image and linux-headers packages:

apt-get update && apt-get upgrade
apt-cache search linux-image

then search latest linux-image and linux-source packages with the same version. In my case output was

linux-headers-4.17.0-kali1-amd64 - Header files for Linux 4.17.0-kali1-amd64
linux-headers-4.17.0-kali1-cloud-amd64 - Header files for Linux 4.17.0-kali1-cloud-amd64
linux-image-4.17.0-kali1-amd64 - Linux 4.17 for 64-bit PCs
linux-image-4.17.0-kali1-amd64-dbg - Debug symbols for linux-image-4.17.0-kali1-amd64
...

so then I just installed latest versions:

apt-get install linux-headers-4.17.0-kali1-amd64 linux-image-4.17.0-kali1-amd64 -y
reboot

Upvotes: 8

Delmys Asteroraena
Delmys Asteroraena

Reputation: 35

First of all try to change the line

linux-headers-4.15.0-kali2-amd64

to

linux-headers-4.15.0-kali-amd64

Because there are no kali2 thing at all.

Also what you can do is to run

apt-cache search linux-headers

It will show all available headers.

Upvotes: -2

Related Questions