Debian Mint openSUSE Red Hat Ubuntu

How to Setup Automatic Kernel Updates on Linux

How to Setup Automatic Kernel Updates on Linux


We can use apt, yum or kexec to update the Linux kernel but when managing a lot of servers, it takes a lot of time.

We must reboot the system if the update manually. This makes you must wait so long. And it also has low security that hackers can attack the system at any time during the break. When you manage a lot of servers, automatic updating the kernel is a better option.

Below is the guide on how to update kernel automatically on Linux as we go through below.

Canonical Livepatch

Canonical Livepatch is a running kernel patching service without rebooting the Ubuntu system. Livepatch is a free service and can use up to 3 Ubuntu systems.

Before installing the service, you must get a livepatch token from the

Click to the Ubuntu user then click to the Get your Livepatch token.

Create a new account.

Then go back to the link and Get your Livepatch token.


$ sudo snap install canonical-livepatch

$ sudo canonical-livepatch enable <your-key>

Checking service information:

$ sudo canonical-livepatch status --verbose


To unregister a machine, run:

$ sudo canonical-livepatch disable <your-key>


KernelCare is based on Ubuntu, CentOS, Debian, and other Linux distributions. If you are a hosting provider or business, you should use it.

Run the wget command to install it:

$ wget -qq -O - | bash

If you’re using a key-based license, run:

$ /usr/bin/kcarectl --register <your-key>

You can get <your-key> from

To check if the running kernel is supported by KernelCare:

$ curl -s -L | python

Unregistering a server:

$ sudo kcarectl --unregister

Checking service information:

$ sudo kcarectl --info

Updating manually, run:

$ /usr/bin/kcarectl --update


You have just seen detailed instructions on how to set up automatic kernel updates on Linux.

Thank you for reading.

Similar Posts