- Install tools to build:
sudo apt-get update
sudo apt-get install kernel-package fakeroot wget bzip2
- Linux-2.6.39.1-linode34 is same as regular 2.6.38 source: http://forum.linode.com/viewtopic.phpt=6949&sid=cd983a6b71bb77bff08160fb55f67d12
cd ~/src
wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.39.3.tar.bz2
- Build
tar xjf linux-2.6.39.3.tar.bz2
cd linux-2.6.39.3
# Restore config
zcat /proc/config.gz > .config
make-kpkg clean
fakeroot make-kpkg --initrd --append-to-version=-linode34 kernel_headers
- After it finishes compiling:
cd ..
sudo dpkg -i linux-headers-2.6.39.3-linode34_2.6.39.3-linode34-10.00.Custom_i386.deb
cd /usr/src
sudo ln -s linux-headers-2.6.39.3-linode34 linux-headers-2.6.39.1-linode34
cd /lib/modules/2.6.39.1-linode34
sudo ln -s /usr/src/linux-headers02.6.39.1-linode34 build
when I run : sudo dpkg -i linux-headers-2.6.39.3-linode34_2.6.39.3-linode34-10.00.Custom_amd64.deb
it report error:
Selecting previously unselected package linux-headers-2.6.39.3-linode34.
(Reading database ... 218157 files and directories currently installed.)
Preparing to unpack linux-headers-2.6.39.3-linode34_2.6.39.3-linode34-10.00.Custom_amd64.deb ...
Unpacking linux-headers-2.6.39.3-linode34 (2.6.39.3-linode34-10.00.Custom) ...
Setting up linux-headers-2.6.39.3-linode34 (2.6.39.3-linode34-10.00.Custom) ...
Examining /etc/kernel/header_postinst.d.
run-parts: executing /etc/kernel/header_postinst.d/dkms 2.6.39.3-linode34 /boot/vmlinuz-2.6.39.3-linode34
Error! Your kernel headers for kernel 2.6.39.3-linode34 cannot be found.
Please install the linux-headers-2.6.39.3-linode34 package,
or use the --kernelsourcedir option to tell DKMS where it's located