Page 1 of 2 12 LastLast
Results 1 to 50 of 60

Thread: Kernel headers problem

  1. #1
    Join Date
    2013-May
    Posts
    12

    Kernel headers problem

    Hey guys,

    My problem is when i try to update the kernel headers, i get the following;

    Code:
    root@localhost:~# apt-get install linux-headers-`uname -r`
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    E: Unable to locate package linux-headers-3.7-trunk-686-pae
    E: Couldn't find any package by regex 'linux-headers-3.7-trunk-686-pae'

    anyone have a solution for me?

  2. #2
    Did you do update before?
    Code:
    apt-get update
    Also check to make sure your source file is correct:
    Kali users should have these entries in their /etc/apt/sources.list file:
    Code:
    deb http://http.kali.org/kali kali main contrib non-free
    deb http://security.kali.org/kali-security kali/updates main contrib non-free
    Source: http://docs.kali.org/frequently-asked-questions

  3. #3
    Join Date
    2013-May
    Posts
    12
    Yeah i added a few more update sources, done a apt-get update, fixed the problem.

    was tough to find for a must needed fix for Kali.

  4. #4
    Join Date
    2013-May
    Posts
    1
    Hi,

    I am Sunny...new to this group
    Even i was facing the same issue
    Trying to install VMWare on Kali ....it says kernel headers for version 3.7-trunk-686-pae not found....tried a lot to get in and finally found the above mentioned cmd
    apt-get install linux-headers-`uname -r`....................which doesn't fetch expected output

  5. #5
    Join Date
    2013-May
    Posts
    12
    Ive done two installs;

    One laptop: i updated only kernel headers, i can log off properly (no blank black screen and i cant do anything)

    One computer: updated all updates, inc kernel headers, cant log off properly. i get a black screen, no login line.

    Why is the first release of this so buggy & doesn't include sources for kernel updates?

  6. #6
    Join Date
    2013-Mar
    Location
    asia
    Posts
    1
    Quote Originally Posted by Philly View Post
    Hey guys,

    My problem is when i try to update the kernel headers, i get the following;

    Code:
    root@localhost:~# apt-get install linux-headers-`uname -r`
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    E: Unable to locate package linux-headers-3.7-trunk-686-pae
    E: Couldn't find any package by regex 'linux-headers-3.7-trunk-686-pae'

    anyone have a solution for me?
    Hi Philly, i had same problem like you but i tried to do what g0tmi1k said and it works..

    Quote Originally Posted by g0tmi1k View Post
    Did you do update before?
    Code:
    apt-get update
    Also check to make sure your source file is correct:

    Source: http://docs.kali.org/frequently-asked-questions
    hi g0tmi1k, i tried what you said and it works... Thanks

  7. #7
    Join Date
    2014-Jan
    Posts
    1
    I've run across this same issue, however I've followed all the steps listed in this thread, and still receive the same error. I've visted the faq page and added all the deb and deb-src listings, ran the apt-get update, but still can't get guest additions to load correctly.


    root@kali:~# apt-get install -y linux-headers-$(uname -r)
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    E: Unable to locate package linux-headers-3.7-trunk-686-pae
    E: Couldn't find any package by regex 'linux-headers-3.7-trunk-686-pae'


    Any other ideas?

  8. #8
    Join Date
    2014-Jan
    Posts
    14
    I have tried the above, but doesnt work for me.
    The 2 links below is
    root@E33:~# cat /etc/apt/sources.list
    deb http://http.kali.org/kali kali main contrib non-free
    deb http://security.kali.org/kali-security kali/updates main contrib non-free
    root@E33:~# apt-get update
    Hit http://http.kali.org kali Release.gpg
    Hit http://security.kali.org kali/updates Release.gpg
    Hit http://http.kali.org kali Release
    Hit http://security.kali.org kali/updates Release
    Get:1 http://http.kali.org kali/main amd64 Packages [8,424 kB]
    Get:2 http://security.kali.org kali/updates/main amd64 Packages [143 kB]
    Hit http://http.kali.org kali/contrib amd64 Packages
    Hit http://security.kali.org kali/updates/contrib amd64 Packages
    Hit http://security.kali.org kali/updates/non-free amd64 Packages
    Hit http://http.kali.org kali/non-free amd64 Packages
    Ign http://http.kali.org kali/contrib Translation-en_US
    Ign http://security.kali.org kali/updates/contrib Translation-en_US
    Ign http://security.kali.org kali/updates/contrib Translation-en
    Ign http://http.kali.org kali/contrib Translation-en
    Ign http://security.kali.org kali/updates/main Translation-en_US
    Ign http://http.kali.org kali/main Translation-en_US
    Ign http://security.kali.org kali/updates/main Translation-en
    Ign http://http.kali.org kali/main Translation-en
    Ign http://security.kali.org kali/updates/non-free Translation-en_US
    Ign http://http.kali.org kali/non-free Translation-en_US
    Ign http://security.kali.org kali/updates/non-free Translation-en
    Ign http://http.kali.org kali/non-free Translation-en
    Fetched 2 B in 22s (0 B/s)
    W: Failed to fetch gzip:/var/lib/apt/lists/partial/http.kali.org_kali_dists_kali_main_binary-amd64_Packages Hash Sum mismatch

    W: Failed to fetch gzip:/var/lib/apt/lists/partial/security.kali.org_kali-security_dists_kali_updates_main_binary-amd64_Packages Hash Sum mismatch

    E: Some index files failed to download. They have been ignored, or old ones used instead.
    root@E33:~#
    So, linux-headers-3.7-trunk-amd64 cannot be installed
    root@E33:~# apt-get install linux-headers-$(uname -r)
    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    E: Unable to locate package linux-headers-3.7-trunk-amd64
    E: Couldn't find any package by regex 'linux-headers-3.7-trunk-amd64'
    root@E33:~#
    Any idea?

  9. #9
    Join Date
    2014-Jan
    Posts
    14
    I have change the link below with its mirror:
    deb http://http.kali.org/kali kali main contrib non-free
    deb http://security.kali.org/kali-security kali/updates main contrib non-free

    so the apt-get update works fine without any problem, but still Couldn't find any package by regex 'linux-headers-3.7-trunk-amd64'

    No any moderator for Kali can advise or give us a hint?
    This issue should be fixed before anything I think.

    Regards

  10. #10
    Join Date
    2014-Jan
    Posts
    1
    This is what I've done.

    apt-get update
    everything updated just fine
    apt-get upgrade
    everything upgraded
    apt-get install linux-headers-$(uname -r)
    Building dependency tree
    Reading state information... Done
    E: Unable to locate package linux-headers-3.7-trunk-686-pae
    E: Couln't find any package by regex 'linux-headers-3.7-trunk-686-pae'

    The source list is fine and does have these two
    deb http://http.kali.org/kali kali main contrib non-free
    deb http://security.kali.org/kali-security kali/updates main contrib non-free
    So what I did was search if any was in the cache.
    apt-cache search linux-headers
    linux-headers-3.12-kalil-484 - Header files for linux 3.12-kalil-486
    linux-headers-3.12-kalil686-pae - header files for linux 3.12-kalil-686-pae
    linux-headers-3.12-kalil-al - all headr files for Linux 3.12 (meta-package)
    linux-headers-3.12-kalil-amd64 - header files for linux 3.12-kalil-amd64
    linux-headers-3.12-kalil-common - Common header files for linux 3.12-kalil
    linux-headers-3.12-kalil-common-rt - common header files for linux 3.12-kalil-rt
    linux-headers-3.12-kalil-rt686-pae - Header files for Linux 3.12-kalil-rt-686-pae
    linux-headers-484 - Header files for Linux 486 configuration (meta-package)
    linux-headers-amd64 - Header files for linux amd64 configuration (meta-package)
    linux-headers-rt-686-pae - Header files for Linux rt-686-pae configuration (meta-package)

    Why is it giving me 3.12 when I need 3.7? A bit of help would be awesome.

  11. #11
    Join Date
    2014-Jan
    Posts
    2
    I'm getting exactly the same like curemymind ... sources.list is up to date, but I'm still receiving

    E: Unable to locate package linux-headers-3.7-trunk-686-pae
    E: Couln't find any package by regex 'linux-headers-3.7-trunk-686-pae'

    very annoying :/ ... free hug for a solution

  12. #12
    Join Date
    2013-Mar
    Posts
    354
    I belive they were pulled out of the repos. You might want to upgrade the kernel and then install their headers.

    Sorry, I belive there is no 3.7 headers.

  13. #13
    Join Date
    2014-Jan
    Posts
    2
    ah ok, thanks for the advice!

    i just saw that kali 1.0.6 were recently released and did the following to update :

    Code:
    apt-get update
    apt-get dist-upgrade
    like they mention at the following URL Kali 1.0.6 Released/

    I will give it a try!

  14. #14
    Join Date
    2014-Jan
    Posts
    14
    Quote Originally Posted by haxxley View Post

    I will give it a try!
    were you able to upgrade to kali 1.06?

  15. #15
    Join Date
    2013-Mar
    Posts
    354
    If you want to upgrade (packages, kernel and drivers), which I strongly belive is the new version, I always do the this in my debian (wheezy backports, testing, sid and kali) computers:

    1. aptitude clean (to cleanup all the /var/cache/apt/archives, and avoid some update and gpg KEY problems)
    2. Need to have installed in your system:
    linux-image-amd64 (for 64bit systems) or the 32-bit image for 32bit systems
    linux-headers-amd64 (for 64bit systems or the 32-bit image for 32bit systems)
    firmware-linux (for linux free and non-free firmwares to drivers)
    This way every aptitude safe-upgrade and full-upgrade will automatically install new kernel if any, new firmwares and new headers according to the new kernel.
    3. aptitude safe-upgrade (very important to do this step before any full-upgrade, since this will not remove any package which dependencies are not met by other packages) READ man aptitude.
    4. again step 2 in case some package was not safe-upgraded (hardly will happen, but "hardly or 99% is not enough).
    5. aptitude full-upgrade (if you are a debianist, you know the dist-upgrade is deprecated but still in use, read the man aptitude).

    That's it...At least I never re-install kali every new version, since you will have updated packages and libraries with safe and full upgrades.

    Luck.

  16. #16
    Join Date
    2014-Jan
    Location
    world wide
    Posts
    9
    Quote Originally Posted by maverik35 View Post
    If you want to upgrade (packages, kernel and drivers), which I strongly belive is the new version, I always do the this in my debian (wheezy backports, testing, sid and kali) computers:

    1. aptitude clean (to cleanup all the /var/cache/apt/archives, and avoid some update and gpg KEY problems)
    2. Need to have installed in your system:
    linux-image-amd64 (for 64bit systems) or the 32-bit image for 32bit systems
    linux-headers-amd64 (for 64bit systems or the 32-bit image for 32bit systems)
    firmware-linux (for linux free and non-free firmwares to drivers)
    This way every aptitude safe-upgrade and full-upgrade will automatically install new kernel if any, new firmwares and new headers according to the new kernel.
    3. aptitude safe-upgrade (very important to do this step before any full-upgrade, since this will not remove any package which dependencies are not met by other packages) READ man aptitude.
    4. again step 2 in case some package was not safe-upgraded (hardly will happen, but "hardly or 99% is not enough).
    5. aptitude full-upgrade (if you are a debianist, you know the dist-upgrade is deprecated but still in use, read the man aptitude).

    That's it...At least I never re-install kali every new version, since you will have updated packages and libraries with safe and full upgrades.

    Luck.
    After I do these Steps, my Kali doesn't working. I cant start startx and the Network isn't working. Wlan and Lan.

    What can I do ?

  17. #17
    Join Date
    2013-Mar
    Posts
    354
    Did you do exactly the steps?..I did 5 days ago and it runs like a charm. This is the third time I do this...

    Any errors reported during safe-upgrade?....

    Do you have VM or HDD installation?...Any errors reported after rebooting. Do you get to the grub menu?

    Need more info.

  18. #18
    Join Date
    2014-Jan
    Location
    world wide
    Posts
    9
    I did a clean install of Kali 1.06 now.

    I try to install Nvidia Drivers for Pyrit but I have a problem with the Linux-Headers.

    When I type apt-get install -y linux-headers-$(uname -r)

    I get this

    Code:
    root@cray7:~# apt-get install -y linux-headers-$(uname -r)
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    E: Unable to locate package linux-headers-3.12-kali1-686-pae
    E: Couldn't find any package by regex 'linux-headers-3.12-kali1-686-pae'
    root@cray7:~#

  19. #19
    Join Date
    2014-Jan
    Posts
    14
    Quote Originally Posted by maverik35 View Post
    Any errors reported during safe-upgrade?....
    @marverik35
    Can you please post the source.list?
    I couldn't complete the command aptitude safe-upgradedue to unavailablity for some packages

  20. #20
    Join Date
    2014-Jan
    Posts
    14
    Finally it works by downloading fresh final version and changing the repository to different mirror as per Thanks to g0tmi1k

  21. #21
    Join Date
    2013-Jun
    Posts
    16
    Quote Originally Posted by f0xp View Post
    I did a clean install of Kali 1.06 now.

    I try to install Nvidia Drivers for Pyrit but I have a problem with the Linux-Headers.

    When I type apt-get install -y linux-headers-$(uname -r)

    I get this

    Code:
    root@cray7:~# apt-get install -y linux-headers-$(uname -r)
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    E: Unable to locate package linux-headers-3.12-kali1-686-pae
    E: Couldn't find any package by regex 'linux-headers-3.12-kali1-686-pae'
    root@cray7:~#
    I'm getting the exact same problem. A fresh install didn't fix it. I've already tried different sources, but nothing seems to work; any ideas? I will keep trying sources and report back.
    Edit:
    Apt-cache search even shows that I have 3.12 kernel headers, but they aren't found when I try to install them.
    Last edited by carltom46; 2014-01-23 at 17:33.

  22. #22
    Join Date
    2013-Jun
    Posts
    16
    Quote Originally Posted by carltom46 View Post
    I'm getting the exact same problem. A fresh install didn't fix it. I've already tried different sources, but nothing seems to work; any ideas? I will keep trying sources and report back.
    Edit:
    Apt-cache search even shows that I have 3.12 kernel headers, but they aren't found when I try to install them.
    I am getting this in my 3 VM's, along with my main Kali Desktop. A temporary solution for Virtualbox, for example, is to boot into the 3.7 kernel instead of the 3.12, so that the Virtualbox Guest Additions work fine. However, even under the 3.7 kernel, trying to update the kernel headers yields the same result (although the package name now says 3.7, obviously).

  23. #23
    Join Date
    2014-Jan
    Location
    Israel
    Posts
    3
    Hi, all..

    I think my kali disro is upgreaded to the lastest version.

    uname -r
    3.12-kali1-686-pae

    I was succeded to install kernel headers by the following command

    apt-get install linux-headers-`uname -r`

    Here is the source file content
    cat /etc/apt/
    deb http://http.kali.org/kali kali main non-free contrib
    deb http://security.kali.org/kali-security kali/updates main contrib non-free

    deb-src http://http.kali.org/kali kali main non-free contrib
    deb-src http://security.kali.org/kali-security kali/updates main contrib non-free

  24. #24
    Join Date
    2014-Jan
    Posts
    14
    carltom46@

    try to comment all lines in source.list and insert the line below if you are using 1.06 version:
    deb http://ftp.halifax.rwth-aachen.de/kali/ kali main non-free contrib
    deb http://ftp.halifax.rwth-aachen.de/kali-security/ kali main non-free contrib
    Last edited by lee_can; 2014-01-23 at 21:26.

  25. #25
    Join Date
    2013-Jun
    Posts
    16
    Quote Originally Posted by @sapiens View Post
    Hi, all..

    I think my kali disro is upgreaded to the lastest version.

    uname -r
    3.12-kali1-686-pae

    I was succeded to install kernel headers by the following command

    apt-get install linux-headers-`uname -r`

    Here is the source file content
    cat /etc/apt/
    deb http://http.kali.org/kali kali main non-free contrib
    deb http://security.kali.org/kali-security kali/updates main contrib non-free

    deb-src http://http.kali.org/kali kali main non-free contrib
    deb-src http://security.kali.org/kali-security kali/updates main contrib non-free
    Quote Originally Posted by lee_can View Post
    carltom46@

    try to comment all lines in source.list and insert the line below if you are using 1.06 version:
    I've tried commenting my original sources.list, adding both of these two lines together, as well as adding them in separately, but both times I get the error:

    Code:
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    E: Unable to locate package linux-headers3.12-kali1-amd64
    E: Couldn't find any package by regex 'linux-headers3.12-kali1-amd64'

  26. #26
    Join Date
    2014-Jan
    Posts
    14
    Before installing the linux header, did you clean your cache then make apt-get update?

  27. #27
    Join Date
    2014-Jan
    Location
    Israel
    Posts
    3
    Procceed to install Linux headers after completing apt-get update
    Use only the repositories from here http://docs.kali.org/general-use/kal...t-repositories

    apt-get clean to clean cache

  28. #28
    Join Date
    2013-Mar
    Posts
    4
    Are you running this in a virtual box

    apt-get update && apt-get install -y linux-headers-$(uname -r)

  29. #29
    Join Date
    2014-Jan
    Posts
    1
    I am having the exact same problem. I am wondering if it is related to the latest version of Virtual Box? I am running v 4.3.6 r91406. I have tried a half-dozen variants of the sources.list, to no avail. I have run apt-get upgrade and apt-get update before running apt-get install -y linux-headers-$(uname -r).

    in my case, it can't locate 'linux-headers-3.7-trunk-amd64'

    what other info can I provide to help us figure out why apt can't find the files?

  30. #30
    Join Date
    2013-Jun
    Posts
    16
    Quote Originally Posted by @sapiens View Post
    Hi, all..

    I think my kali disro is upgreaded to the lastest version.

    uname -r
    3.12-kali1-686-pae

    I was succeded to install kernel headers by the following command

    apt-get install linux-headers-`uname -r`

    Here is the source file content
    cat /etc/apt/
    deb http://http.kali.org/kali kali main non-free contrib
    deb http://security.kali.org/kali-security kali/updates main contrib non-free

    deb-src http://http.kali.org/kali kali main non-free contrib
    deb-src http://security.kali.org/kali-security kali/updates main contrib non-free
    I've figured it out. I tried as @sapiens suggested, but it did not work. However, I then did sudo uname -r, copied the kernel name, then did sudo apt-get install linux-headers-'INSERT_KERNEL_NAME_HERE', and it worked perfectly. Thanks for the tip @sapiens; it seems as if the old, apt-get install linux-headers-$(uname -r) doesn't work anymore.

  31. #31
    Join Date
    2014-Jan
    Location
    Israel
    Posts
    3
    Thanks, for tip. I'm glad that your solution works for you.

  32. #32
    Join Date
    2014-Jan
    Posts
    3
    I am having same problem , I gave done apt-get update using all repositories , omitting them and leave two in the source file list but I keep getting unable to locate packages error as above posts. Any more news on a fix ? I only want to install cuda

  33. #33
    Join Date
    2013-Jun
    Posts
    16
    Quote Originally Posted by emmanneil View Post
    I am having same problem , I gave done apt-get update using all repositories , omitting them and leave two in the source file list but I keep getting unable to locate packages error as above posts. Any more news on a fix ? I only want to install cuda
    Did you try using apt-get install linux-headers-'INSERT_KERNEL_NAME_HERE', rather than apt-get install linux-headers$(uname -r)?

    Edit:
    You can find your kernel name by using uname -r.

  34. #34
    Join Date
    2014-Jan
    Posts
    1
    Everybody here is the simple solution: in the command line there's a missing space between "headers" and "$"

    So try this: apt-get install linux-headers $(uname -r)

  35. #35
    Join Date
    2014-Jan
    Posts
    1
    I had the same problem and solved it adding deb-src for the security (copy the line and add -src) in /apt/sources.list so:
    deb-src http://security.kali.org/kali-security kali/updates main contrib non-free
    standard I had the distribution, the source of the distribution and the security updates without source.
    And afterwards I did
    apt-get install linux-headers-$(uname -r)
    so no spaces... ;-)

  36. #36
    Join Date
    2014-Jan
    Posts
    3
    Quote Originally Posted by jdeca57 View Post
    I had the same problem and solved it adding deb-src for the security (copy the line and add -src) in /apt/sources.list so:
    deb-src http://security.kali.org/kali-security kali/updates main contrib non-free
    standard I had the distribution, the source of the distribution and the security updates without source.
    And afterwards I did
    apt-get install linux-headers-$(uname -r)
    so no spaces... ;-)
    I have tried all the above but still no sucess

    this is the output after doing apt-get update and apt-get upgrade

    root@kali:/# uname -r
    3.7-trunk-686-pae

    and

    root@kali:/# apt-cache search linux-headers
    linux-headers-3.12-kali1-486 - Header files for Linux 3.12-kali1-486
    linux-headers-3.12-kali1-686-pae - Header files for Linux 3.12-kali1-686-pae
    linux-headers-3.12-kali1-all - All header files for Linux 3.12 (meta-package)
    linux-headers-3.12-kali1-all-i386 - All header files for Linux 3.12 (meta-package)
    linux-headers-3.12-kali1-amd64 - Header files for Linux 3.12-kali1-amd64
    linux-headers-3.12-kali1-common - Common header files for Linux 3.12-kali1
    linux-headers-3.12-kali1-common-rt - Common header files for Linux 3.12-kali1-rt
    linux-headers-3.12-kali1-rt-686-pae - Header files for Linux 3.12-kali1-rt-686-pae
    linux-headers-486 - Header files for Linux 486 configuration (meta-package)
    linux-headers-686-pae - Header files for Linux 686-pae configuration (meta-package)
    linux-headers-amd64 - Header files for Linux amd64 configuration (meta-package)
    linux-headers-rt-686-pae - Header files for Linux rt-686-pae configuration (meta-package)


    any ideas?

  37. #37
    Join Date
    2014-Apr
    Posts
    1

    The problem can be solved~

    Quote Originally Posted by Philly View Post
    Hey guys,

    My problem is when i try to update the kernel headers, i get the following;

    Code:
    root@localhost:~# apt-get install linux-headers-`uname -r`
    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    E: Unable to locate package linux-headers-3.7-trunk-686-pae
    E: Couldn't find any package by regex 'linux-headers-3.7-trunk-686-pae'

    anyone have a solution for me?


    I looked for the solution for a long time , but there is a way that can get the problem solved , the detailed information can be seen in the following URL: http://www.geekyindians.com/content/...additions-kali , the method has been proved effectively.

  38. #38
    Join Date
    2014-Apr
    Posts
    1
    I had the same issue. I found the solution here (in the comments) -> http://pantuts.com/2013/03/14/how-to...ernel-headers/

    jinx says:
    July 30, 2013 at 8:15 am

    to fix ur error,try the following:
    –>add repositories: open the /etc/apt/sources.list file in your favourite text editor as root, and paste the following lines ONLY the one missing from ur source list :
    deb http://http.kali.org/ /kali main contrib non-free
    deb http://http.kali.org/ /wheezy main contrib non-free
    deb http://http.kali.org/kali kali-dev main contrib non-free
    deb http://http.kali.org/kali kali-dev main/debian-installer
    deb-src http://http.kali.org/kali kali-dev main contrib non-free
    deb http://http.kali.org/kali kali main contrib non-free
    deb http://http.kali.org/kali kali main/debian-installer
    deb-src http://http.kali.org/kali kali main contrib non-free
    deb http://security.kali.org/kali-security kali/updates main contrib non-free
    deb-src http://security.kali.org/kali-security kali/updates main contrib non-free
    deb http://repo.kali.org/kali kali-bleeding-edge main
    –>SAVE and then UPDATE ur system

  39. #39
    Join Date
    2013-Mar
    Location
    NYC
    Posts
    11
    To fix this problem all you need to do is open your sources.lst file in LeafPad which is located at /etc/apt/sources.list
    then once it is open you need to delete the # in front of deb http://security.kali.org/kali-security kali/updates main contrib non-free

    and then paste the following below it:

    deb http://http.kali.org/kali kali main non-free contrib

    deb-src http://http.kali.org/kali kali main non-free contrib

    Once you have done this save and close LeafPad & open a terminal and type sudo apt-get update

    and then

    apt-get install build-essential linux-headers-`uname -r`

    Problem solved

  40. #40
    try sudo apt-get upgrade linux-headers

  41. #41
    Join Date
    2015-Jul
    Posts
    1
    Check /etc/apt/sourses.lst
    Was
    deb http://security.kali.org/ kali/updates main contrib non-free
    deb-src http://security.kali.org/ kali/updates main contrib non-free

    and I received error as described above like
    E: Unable to locate package linux-headers-3.0.18-686-pae
    E: Couldn't find any package by regex 'linux-headers-3.0.18-686-pae'


    Now /etc/apt/sourses.lst is

    deb http://security.kali.org/ kali/updates main contrib non-free
    deb http://http.kali.org/kali/ kali-current main non-free contrib

    deb-src http://security.kali.org/ kali/updates main contrib non-free
    deb-src http://http.kali.org/kali kali-current main non-free contrib

    and
    apt-get install build-essential linux-headers-`uname -r`
    work without errors.

  42. #42
    Join Date
    2015-Aug
    Posts
    1
    I can't seem to install the headers for Kali 2.0. What I did was:
    Code:
    # apt-get update
    # apt-get upgrade && apt-get dist-upgrade
    # apt-get install linux-headers-$(uname -r)
    The respone I got was:
    Code:
    Paketlisten werden gelesen... Fertig
    Abhängigkeitsbaum wird aufgebaut.
    Statusinformationen werden eingelesen.... Fertig
    E: Paket linux-headers-4.0.0-kali1-amd64 kann nicht gefunden werden.
    E: Mittels regulärem Ausdruck »linux-headers-4.0.0-kali1-amd64« konnte kein Paket gefunden werden.
    My /etc/apt/sources.list reads:
    Code:
    cat /etc/apt/sources.list
    #
    deb http://security.kali.org/kali-security/ sana/updates main contrib non-free
    deb-src http://security.kali.org/kali-security/ sana/updates main contrib non-free
    deb http://repo.kali.org/kali kali-bleeding-edge main
    Any ideas?

  43. #43
    Join Date
    2015-Jul
    Location
    Cyberworld
    Posts
    6
    i have same problem. is there any new source i need to add? because it cant find package for 4.0.0 header
    apt-get update && apt-get install -y linux-headers-$(uname -r)
    used to work for previous version, but not for kali

  44. #44
    Join Date
    2015-Aug
    Posts
    8
    For Kali 2.0, I had the same issue, but it was due to the sources.list not including the http.kali.org entries from a vanilla install using the amd64 ISO. Add these into there and you should be able to locate the package correctly afterwards.

    /etc/apt/sources.list:
    Code:
    # Regular Repositories
    deb http://http.kali.org/kali sana main non-free contrib
    deb http://security.kali.org/kali-security sana/updates main contrib non-free
    
    # Source Repositories
    deb-src http://http.kali.org/kali sana main non-free contrib
    deb-src http://security.kali.org/kali-security sana/updates main contrib non-free
    Then, you can update and install linux-headers:
    Code:
    apt-get update
    apt-get install linux-headers-$(uname -r)

  45. #45
    Join Date
    2015-Aug
    Posts
    2
    Quote Originally Posted by Cashiuus View Post
    For Kali 2.0, I had the same issue, but it was due to the sources.list not including the http.kali.org entries from a vanilla install using the amd64 ISO. Add these into there and you should be able to locate the package correctly afterwards.

    /etc/apt/sources.list:
    Code:
    # Regular Repositories
    deb http://http.kali.org/kali sana main non-free contrib
    deb http://security.kali.org/kali-security sana/updates main contrib non-free
    
    # Source Repositories
    deb-src http://http.kali.org/kali sana main non-free contrib
    deb-src http://security.kali.org/kali-security sana/updates main contrib non-free
    Then, you can update and install linux-headers:
    Code:
    apt-get update
    apt-get install linux-headers-$(uname -r)
    This worked for me. Thanks for the help!

  46. #46
    Quote Originally Posted by zyrill View Post
    I can't seem to install the headers for Kali 2.0. What I did was:
    ...SNIP...
    My /etc/apt/sources.list reads:
    Code:
    cat /etc/apt/sources.list
    #
    deb http://security.kali.org/kali-security/ sana/updates main contrib non-free
    deb-src http://security.kali.org/kali-security/ sana/updates main contrib non-free
    deb http://repo.kali.org/kali kali-bleeding-edge main
    Any ideas?

    Your source file is wrong. Check: http://docs.kali.org/general-use/kal...t-repositories
    This is a Kali-Linux support forum - not general IT/infosec help.

    Useful Commands: OS, Networking, Hardware, Wi-Fi
    Troubleshooting: Kali-Linux Installation, Repository, Wi-Fi Cards (Official Docs)
    Hardware: Recommended 802.11 Wireless Cards

    Documentation: http://docs.kali.org/ (Offline PDF version)
    Bugs Reporting & Tool Requests: https://bugs.kali.org/
    Kali Tool List, Versions & Man Pages: https://tools.kali.org/

  47. #47
    Join Date
    2015-Nov
    Posts
    1
    Quote Originally Posted by Cashiuus View Post
    For Kali 2.0, I had the same issue, but it was due to the sources.list not including the http.kali.org entries from a vanilla install using the amd64 ISO. Add these into there and you should be able to locate the package correctly afterwards.

    /etc/apt/sources.list:
    Code:
    # Regular Repositories
    deb http://http.kali.org/kali sana main non-free contrib
    deb http://security.kali.org/kali-security sana/updates main contrib non-free
    
    # Source Repositories
    deb-src http://http.kali.org/kali sana main non-free contrib
    deb-src http://security.kali.org/kali-security sana/updates main contrib non-free
    Then, you can update and install linux-headers:
    Code:
    apt-get update
    apt-get install linux-headers-$(uname -r)
    What do I need to do if it says permission denied?

  48. #48
    Join Date
    2015-Oct
    Location
    Switzerland
    Posts
    33
    Hi AAA

    Are you root?
    Otherwise run the command with "sudo" at the beginning or change to root by tipping "sudo su"..

    regards, reidamaxia

  49. #49
    Join Date
    2015-Dec
    Posts
    1

    Angry

    Hi users
    I have no problem to install kernel in kali sana
    All the above steps did all the things you think what I'm still not installed

    PHP Code:
    root@dhcppc2:~# apt-get install linux-headers-`uname -r`
    Reading package lists... Done
    Building dependency tree       
    Reading state information
    ... Done
    E
    Unable to locate package linux-headers-4.0.0-kali1-amd64
    E
    Couldn't find any package by regex 'linux-headers-4.0.0-kali1-amd64'
    root@dhcppc2:~# 

  50. #50
    Join Date
    2014-Aug
    Posts
    9
    hello.brand new installation(version 2).i have added http://docs.kali.org/general-use/kal...t-repositories and still i can't install kernel sources.any ideas?

Similar Threads

  1. Cannot install kernel headers (kernel header mismatch)
    By sebos in forum Installing Archive
    Replies: 10
    Last Post: 2022-12-19, 08:11
  2. Fix Kernel Headers Problem
    By Alton Jhon in forum General Archive
    Replies: 5
    Last Post: 2015-03-01, 03:04

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •