How can I check if my Linode's Latest-64bit Kernel is Up to Date?

Linode Staff

I am trying to automatically detect if I am using the latest version of my kernel. Is there any easy way to do this?

1 Reply

You can do this using the Linode-CLI/API.

This command will return Linode's latest 64bit kernel version:

linode-cli kernels view linode/latest-64bit --no-headers --text | awk -F '\t' '{print $2}' | awk -F"[()]" '{print $2}'

# returns

You can then compare that directly to your Linode's kernel version by running this command:

uname -r

For my purposes, since the output does not match, I would then reboot my Linode.

To take this a step further, you could create a cron task to check this automatically. Please note that this would involve installing the Linode-CLI on your Linode.

The command would look something like this:

a="$(linode-cli kernels view linode/latest-64bit --no-headers --text | awk -F '\t' '{print $2}' | awk -F"[()]" '{print $2}')"
b="$(uname -r)"
if [ "$a" != "$b" ]; 
  echo "kernel not up to date - you can reboot using the Linode-CLI command 'linode-cli linodes reboot \$linode_id'"
  echo "kernel is up to date"; 


Please enter an answer

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct