How to Compile and Install Linux Kernel v4.9.11 Source On a Debian / Ubuntu Linux

Here are the steps to compile and install the Linux kernel version 4.9.11 on a Debian or Ubuntu system:

  1. Download the Linux kernel source code:
    wget https://cdn.kernel.org/pub/linux/kernel/v4.x/linux-4.9.11.tar.xz
  2. Extract the source code:
    tar -xvf linux-4.9.11.tar.xz
  3. Change to the extracted source code directory:
    cd linux-4.9.11
  4. Copy the configuration from your current running kernel:
    cp /boot/config-`uname -r` .config
  5. Configure the kernel:
    make menuconfig
  6. Compile the kernel:
    make -j `nproc`
  7. Install the kernel:
    sudo make modules_install install
  8. Update the boot loader:
    sudo update-initramfs -c -k 4.9.11
    sudo update-grub
  9. Reboot your system and select the newly installed kernel from the boot loader menu.

Note: These steps assume that you have the necessary tools and dependencies installed, such as GCC, make, etc. If you don’t have these tools installed, you can install them by running the following command:

sudo apt-get install build-essential

Leave a Comment