升级到18.04版本后找不到'linux-generic-hwe-18.04'。

自从我从16.04升级到18.04以来,我一直看到以下消息:
➜  ~ hwe-support-status 

You have packages from the Hardware Enablement Stack (HWE) installed that
are going out of support on 2023-04-30.

To upgrade to a supported (or longer-supported) configuration:

* Upgrade from Ubuntu 16.04 LTS to Ubuntu 18.04 LTS by running:
sudo do-release-upgrade -p

OR

* Switch to the current security-supported stack by running:
sudo apt-get install linux-generic-hwe-18.04

and reboot your system.
➜  ~ hwe-support-status --show-all-unsupported
➜  ~ hwe-support-status --show-replacements
linux-generic-hwe-18.04
➜  ~ sudo apt-get install linux-generic-hwe-18.04
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package linux-generic-hwe-18.04
E: Couldn't find any package by glob 'linux-generic-hwe-18.04'
E: Couldn't find any package by regex 'linux-generic-hwe-18.04'
➜  ~ sudo do-release-upgrade -p
Checking for a new Ubuntu release
No new release found.
➜  ~ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 18.04.1 LTS
Release:        18.04
Codename:       bionic
➜  ~

有人知道为什么会发生这种情况吗?


现在Ubuntu软件仓库中没有这个包。很有可能以后会创建一个名为linux-generic-hwe-16.04的包。请参考此页面 - N0rbert
这个基本上可以被忽略吗? - fooquency
2你可能已经安装了某个版本的hwe内核包 - 如果你在16.04中进行了hwe更新,那很有可能。如果你运行apt policy linux-generic*命令,你可以看到你安装了哪些类型的内核包。只要你安装了另一个内核包,你很可能可以直接删除有问题的hwe包。 - Organic Marble
修复!感谢Organic Marbles的回复 :) "apt policy linux-generic"显示我安装了"linux-generic-lts-vivid",我删除了它,但仍然收到警告。然后,我修改了hwe-support-status脚本,以便实际告诉我哪个软件包不受支持,并发现我还安装了"linux-headers-generic-lts-vivid"(事后看来,我应该在删除旧内核后运行apt autoremove)。 - Chris
2个回答

18.04目前不需要特定的hwe或lts linux-image(因此不存在)。首先确保已安装了linux-image-generic镜像。
 apt install linux-image-generic

然后删除旧的 HWE 或 LTS Linux 镜像,在我的情况下,我执行了以下操作:
apt purge linux-image-generic-lts-xenial

然后,hwe-support-status命令返回一个干净的空响应。

1我不得不使用aptitude来识别和清除旧的、未使用的*-lts-*镜像。做完之后,一切都正常了。 - baronKarza

我安装了一个旧的不受支持的Linux内核,通过使用
# apt policy linux-generic\*
发现。
记得运行
# apt autoremove
来删除可能被hwe-support-status捕捉到的任何未使用的依赖项。