You Are Here: Home » Articles » How-To » Linux » OS

How to install linux build and kernel headers for ubuntu/debian?

By on June 17th, 2009     

debian-logoInstalling Build and Kernel Headers for your Linux distribution is very easy using the apt-get tool available in Debian based systems. Ubuntu and it's variants being derived from Debian, can also have the Linux Build and Kernel headers installed using the apt-get tool. Just use the following command to install the build and header files for Ubuntu or Debian Linux:

sudo apt-get install linux-headers-$(uname -r)

The uname -r in the above command just passes your kernel version to apt-get. Remember using this command you can install build and kernel headers on all Debian, Ubuntu, kubuntu, Xubuntu and other Debian based Linux Distributions. For Installing Build and Kernel Headers on a RedHat based system, see this.




         Submit to Reddit     Stumble


Related Posts by Tags: , , , , , , , ,



  • Pingback: How to install linux build and kernel headers for fedora/redhat/centos? | Digitizor

  • Pingback: How to install Virtualbox Guest Additions for a Linux Guest? | Digitizor

  • http://www.callum-macdonald.com/ Callum

    On Ubuntu at least, I think it’s better to install the generic kernel headers package. It will always depend on the latest kernel headers, so you’ll always have up to date kernel headers installed.

    Run uname -r to find out what kernel version you have (for example 2.6.24-24-server or 2.6.28-16-generic). Note the final word (in this case -server or -generic) then run sudo apt-get install kernel-headers-server or sudo apt-get install kernel-headers-generic as appropriate.

  • rhizopus

    shouldnt it be <code>sudo apt-get install linux-headers-generic</code> or <code>sudo apt-get install linux-headers-server</code> instead?



How to install linux build and kernel headers for ubuntu/debian? was originally published on Digitizor.com on June 17, 2009 - 3:58 pm (Indian Standard Time)