HowTo: Ubuntu Linux Install Kernel Source Code And Headers

Posted on in Categories last updated April 17, 2013

How do I install Linux kernel source with Ubuntu patches? How can I install Ubuntu Linux kernel source code tree for version 2.6.3x using command line options?

You need to use the apt-get command to install Linux kernel source code. Open the terminal and type the following commands to install Ubuntu Linux source code:
$ sudo apt-get update
$ sudo apt-get install linux-source

Sample outputs:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  linux-source-2.6.32
Suggested packages:
  libncurses-dev ncurses-dev kernel-package libqt3-dev
The following NEW packages will be installed:
  linux-source linux-source-2.6.32
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 65.9MB of archives.
After this operation, 66.0MB of additional disk space will be used.
Do you want to continue [Y/n]? y 

7 comment

Leave a Comment