Disclaimer: As some of our literature may have mentioned before, updating your kernel does carry a (small) risk of breaking your system. If this is the case, it’s usually easy to pick an older kernel at boot time that works, but something may always go wrong. Therefore, we’re not responsible for any damage to your system — use at your own risk!

Prep Work

To update your kernel, you’ll first need to determine whether you’re using a 32-bit or 64-bit system. Open up a terminal window and run

uname -a

Then check to see if the output says x86_64 or i686. If it’s x86_64, then you’re running the 64-bit version; otherwise, you’re running the 32-bit version. Remember this, because it will be important.

Next, visit the official Linux kernel website. This will tell you what the current stable version of the kernel is. You can try out release candidates if you’d like, but they are a lot less tested than the stable releases. Stick with the stable kernel unless you are certain you need a release candidate version.

Ubuntu Instructions

It’s quite easy for Ubuntu and Ubuntu-derivative users to update their kernel, thanks to the Ubuntu Mainline Kernel PPA. Although it’s officially called a PPA, you cannot use it like other PPAs by adding them to your software sources list and expecting it to automatically update the kernel for you. Instead, it’s simply a webpage you navigate through to download the kernel you want.

Now, visit the kernel PPA webpage and scroll all the way to the bottom. The absolute bottom of the list will probably contain some release candidate versions (which you can see by the “rc” in the name), but just above them should be the latest stable kernel (to make this easier to explain, at the time of writing the stable version was 4.1.2). Click on that, and you’ll be presented with several options. You’ll need to grab three files and save them in their own folder (within the Downloads folder if you’d like) so that they’re isolated from all other files:

The header file in the middle that has “all” towards the end of the filename

The “generic” kernel file for your architecture (again, I would pick “amd64” but if you use 32-bit you’ll need “i686”)

You’ll notice that there are also “lowlatency” files available to download, but it’s fine to ignore this. These files are relatively unstable and are only made available for people who need their low-latency benefits if the general files don’t suffice for tasks such as audio recording. Again, the recommendation is to always use generic first and only try lowlatency if your performance isn’t good enough for certain tasks. No, gaming or Internet browsing aren’t excuses to try lowlatency.

You put these files into their own folder, right? Now open up the Terminal, use the

Once the installation is complete, Restart your system and you should be running the just-installed kernel! You can check this by running uname -a in the Terminal and checking the output.

Fedora Instructions

If you use Fedora or one of its derivatives, the process is very similar to Ubuntu. There’s just a different location to grab different files, and a different command to install them.

VIew the list of the most recent kernel builds for Fedora. Pick the latest stable version out of the list, and then scroll down to either the i686 or x86_64 section, depending on your system’s architecture. In this section, you’ll need to grab the following files and save them in their own folder (such as “Kernel” within your Downloads folder, as an example):

kernel

kernel-core

kernel-headers

kernel-modules

kernel-modules-extra

kernel-tools

perf and python-perf (optional)

If your system is i686 (32-bit) and you have 4GB of RAM or more, you’ll need to grab the PAE version of all of these files where available. PAE is an address extension technique used for 32-bit system to allow them to use more than 3GB of RAM.

Upgrading your kernel isn’t easy (done so intentionally), but it can give you a lot of benefits. So long as your new kernel didn’t break anything, you can now enjoy improved performance, better efficiency, support for more hardware, and potential new features. Especially if you’re running relatively new hardware, upgrading the kernel can really help out.

How has upgraded the kernel helped you? Do you think your favorite distribution’s policy on kernel releases is what it should be? Let us know in the comments!

Memory cache is more important for recent computers than before.
The difference of the speed of main memory and cache memory is getting
bigger, and effective utilization of cache memory influence to total
performance of the computer a lot.

Do you have any good idea to improve Linux Kernel? Where(which
part) to improve and how?

It's a lot more locked down than any regular Linux distribution because Google wants to make it as "foolproof" as possible. They also control what kernels are used. As far as I know, it's impossible (or at least extremely difficult).

Thanks for the fine tutorial on loading a new or different kernel package-set from my repositories. This will deliver a new or different kernel binary. I have a different set of interests.

Since I'm running on a laptop, there seem to be numerous built-in or configured kernel parts enabled that have little to do with my available hardware. I would like to turn some of these extra parts off so that my kernel is smaller, lighter, etc. In other words, I'm looking for the kernel equivalent of removing the oriental language fonts from my desktop.

You can try blacklisting modules if you don't want them to run. If you want the actual kernel to be smaller, that's not possible with the methods I described. You would have to download the vanilla kernel from kernel.org and configure and compile it yourself. It's a lot more work that I haven't really done much of.

My take is that quite often software stated as stable is not stable and there are occasions when the distro's kernels do not support some needed devices or features.

Take a recent case where an ODROID kernel feature was required and I had to email details of how to build and install the kernel.

OK, so I have been building kernels since Linus put up the very first one for ftp and I always run the latest, installed not long after it was released some hours ago.
slipstream:~ # uname -r
4.2.0-rc4-smp+

You should make it more clear to upgrade to what.
The distributions provide regular upgrades and users must definitively install them (simply accepting the distro proposition)

But this is different from upgrading to an "unsupported" and riskier kernel version! I agree the risks are low, but multiply by all the versions and the consequences can make you loose way more time than the micro-seconds you may benefits over years.