如何让我的系统使用最新安装的内核?

如何让我的系统使用最新安装的内核?

我最近从 Ubuntu 18.04 升级到 20.04,然后又升级到 22.04。至少在从 20.04 升级到 22.04 时,我收到一个提示,询问我是否要安装最新内核,我回答是(老实说,我记不清从 18.04 升级到 22.04 时到底发生了什么)。

升级似乎成功完成,每次升级后我都重新启动了。但是,尽管安装了新的旧内核,但系统似乎仍在使用旧内核(至少据我所知)。我是否必须在某处指定要使用的内核?

以下是一些可能相关的输出:

$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 22.04.1 LTS
Release:    22.04
Codename:   jammy
        
$ uname -a
Linux r13-003 4.15.0-122-lowlatency #124-Ubuntu SMP PREEMPT Thu Oct 15 13:40:54 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
        
$ apt list --installed | grep linux
    
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
    
binutils-x86-64-linux-gnu/jammy-security,jammy-updates,now 2.38-4ubuntu2.1 amd64 [installed]
console-setup-linux/jammy,now 1.205ubuntu3 all [installed]
libselinux1-dev/jammy,now 3.3-1build2 amd64 [installed,automatic]
libselinux1/jammy,now 3.3-1build2 amd64 [installed]
linux-base/jammy,now 4.5ubuntu9 all [installed]
linux-firmware/jammy-updates,now 20220329.git681281e4-0ubuntu3.9 all [installed]
linux-generic/jammy-security,jammy-updates,now 5.15.0.58.56 amd64 [installed]
linux-headers-5.15.0-58-generic/jammy-security,jammy-updates,now 5.15.0-58.64 amd64 [installed,automatic]
linux-headers-5.15.0-58/jammy-security,jammy-updates,now 5.15.0-58.64 all [installed,automatic]
linux-headers-generic/jammy-security,jammy-updates,now 5.15.0.58.56 amd64 [installed]
linux-image-4.15.0-122-lowlatency/now 4.15.0-122.124 amd64 [installed,local]
linux-image-5.15.0-58-generic/jammy-security,jammy-updates,now 5.15.0-58.64 amd64 [installed,automatic]
linux-image-generic/jammy-security,jammy-updates,now 5.15.0.58.56 amd64 [installed]
linux-libc-dev/jammy-security,jammy-updates,now 5.15.0-58.64 amd64 [installed,automatic]
linux-modules-4.15.0-122-lowlatency/now 4.15.0-122.124 amd64 [installed,local]
linux-modules-5.15.0-58-generic/jammy-security,jammy-updates,now 5.15.0-58.64 amd64 [installed,automatic]
linux-modules-extra-5.15.0-58-generic/jammy-security,jammy-updates,now 5.15.0-58.64 amd64 [installed,automatic]
linux-sound-base/jammy,now 1.0.25+dfsg-0ubuntu7 all [installed,automatic]
python3-selinux/jammy,now 3.3-1build2 amd64 [installed,automatic]
util-linux/jammy,now 2.37.2-4ubuntu3 amd64 [installed]

我想运行 5.15,它似乎已经安装好了,但正如你所见,我目前使用的是 4.15

任何帮助将不胜感激!

答案1

正确识别问题的评论ubfan1——对于具有更多 Linux 经验的人来说可能很明显,但我会在这里发布它,以防其他新手遇到同样的问题。

问题出GRUB_DEFAULT="Advanced options for Ubuntu>Ubuntu, with Linux 4.15.0-122-lowlatency"在 /etc/default/grub 中的行,该行指定了 4.15.0 内核。将此行更改为GRUB_DEFAULT=0并运行sudo update-grub会导致系统在下次重新启动时启动到最新内核。谢谢!

相关内容