LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Debian (https://www.linuxquestions.org/questions/debian-26/)
-   -   Downloading Correct Linux-Headers (https://www.linuxquestions.org/questions/debian-26/downloading-correct-linux-headers-684873/)

bano6010 11-20-2008 08:09 AM

Downloading Correct Linux-Headers
 
Hello,

I am trying to install the Linux headers for my version of Lenny. Although I have no idea what they are or what they are used for, I need them for an install and cant seem to get the ones I need. Heres what I tried.

In a terminal I typed "uname -r" and got "2.6.24-1-amd64". After that I tried "apt-get install linux-headers-2.6.24-1-amd64" and was returned with no such package. I ran "apt-cache search linux-headers" and when I looked at the list I saw only "2.6.26" files. There was "linux-headers-2.6-amd64 which I tired and didn't work. Are there headers available for 2.6.24-1-amd64 or is there a way to get my kernel up to 2.6.26?

Any help would be greatly appreciated. Thanks!

Telemachos 11-20-2008 08:38 AM

All other things being equal, it's probably easiest to simply update your kernel to 2.6.26 and then install those headers. You can install the kernel the same way you install the headers: apt-get install linux-image-2.6.26-1-amd64 linux-headers-2.6.26-1-amd64. If you've compiled any modules (for sound or NVIDIA or wireless), you will need to build new ones, but assuming that you did it once, it's not too hard.

bano6010 11-20-2008 08:53 AM

I ran "apt-get install linux-image-2.6.26-1-amd64" and this is the error I got:

Server:~# apt-get install linux-image-2.6.26-1-amd64
Reading package lists... Done
Building dependency tree
Reading state information... Done
linux-image-2.6.26-1-amd64 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

What I read from that is that I already have it. But when I run "uname -r" again it still produces "2.6.24-1-amd64". Am I doing something wrong or should the system be good to go?

Thanks.

farslayer 11-20-2008 09:27 AM

If uname is showing 2.6.24 instead of 2.6.26 did you reboot the system after updating the kernel to the newer version ?
The one time on a Linux system where a reboot is definitely required is when you update the kernel.

the 2.6.24 headers have been removed from the repository, you may have them on your install media if you really need that old version.
You are better off figuring out why you have installed a newer kernel and are not running it..



aptitude update
aptitude install build-essential module-assistant
m-a update
m-a prepare


that should download and install the proper kernel headers for your system .
to update them in the future, if your kernel gets updated.. just do the last two steps

Telemachos 11-20-2008 08:17 PM

Quote:

Originally Posted by bano6010 (Post 3348672)
I ran "apt-get install linux-image-2.6.26-1-amd64" and this is the error I got:

Server:~# apt-get install linux-image-2.6.26-1-amd64
Reading package lists... Done
Building dependency tree
Reading state information... Done
linux-image-2.6.26-1-amd64 is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

What I read from that is that I already have it. But when I run "uname -r" again it still produces "2.6.24-1-amd64". Am I doing something wrong or should the system be good to go?

Thanks.

Ok, so now you have two kernels installed (not necessarily a bad thing). Reboot and make sure to choose the 2.6.26-1 version, rather than the 2.6.24 version. You should be able to install the headers for the 2.6.26-1 as well.


All times are GMT -5. The time now is 10:55 PM.