Which deb files(http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.7-rc6-yakkety/) are relevant for 64-bit install. The instructions mention not every 64 filename should be installed(https://wiki.ubuntu.com/Kernel/MainlineBuilds).


You want

  • the ones that have generic NOT low latency in the name and
  • the ones that have amd64 NOT arm64 AND
  • the one that ends with 'all'.

That should give you 3 in total:

  • linux-headers-4.7.0-040700rc6-generic_4.7.0-040700rc6.201607040332_amd64.deb
  • linux-headers-4.7.0-040700rc6_4.7.0-040700rc6.201607040332_all.deb
  • linux-image-4.7.0-040700rc6-generic_4.7.0-040700rc6.201607040332_amd64.deb

To uninstall you just have to remove everything relating to that kernel so, assuming you want to remove the kernel linux-image-4.7.0-040700rc6-generic the standard method is:

Boot a different kernel by selecting an older one from GRUB menu: 'Advanced Options for Ubuntu'

Check you booted a different kernel with uname -r - do not delete the running kernel

Find installed packages relating to the kernel using the name string:

dpkg -l | grep 4.7.0-040700rc6

remove all the listed packages with their names (replace with actual names):

sudo apt-get remove name-of-package1 name-of-package2
dpkg --purge name-of-package1 name-of-package2

run sudo update-grub to clean the boot menu

I prefer to use the locate command to remove upstream kernels, because I'm lazy. After booting a different kernel & checking with uname -r do (replace with the name string of the kernel you want to remove):

sudo updatedb
locate -b -e 4.7.0-040700rc6 | xargs -p sudo rm -r
sudo update-grub

You get an error for files that are not directories (because it's trying to remove them recursively), but it still works, and it cleans everything.


Update: The kernel ppa is not maintained anymore. Now the only way is to download and install the image.deb package manually from below url or build kernel for yourself. http://kernel.ubuntu.com/~kernel-ppa/mainline/

You can add kernel-ppa to repo:

sudo apt-add-repository ppa:kernel-ppa/ppa
sudo apt-get update

Then install the linux kernel pacakges you want to.

sudo apt-get install linux-image-xxx

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.