Score:0

Unusual kernel upgrade behaviour Ubuntu 22.04

ve flag

I recently ran an apt upgrade on my system with the following specs:

Kernel: 5.19.0-32-generic
Distro: Ubuntu 22.04.2

And I observed some unusual behaviour during the kernel upgrade

Standard behaviour:

When running apt upgrade, a new kernel version is installed and the current kernel remains unaffected. When running apt autoremove, the previous kernel is removed so only two kernels are present. Older kernel versions are never downloaded when using apt upgrade.

Current behaviour:

Both kernels 5.19.0-35-generic and 5.15.0-67-generic were installed, and when I ran apt autoremove, only kernel 5.15.0-60-generic was removed, leaving three kernels installed in the system.

Question:

Why is the 5.15 kernel being distributed again while the distro has migrated to 5.19? Why are three kernels kept instead of two? In this case, 5.15.0-67-generic, 5.19.0-32-generic, and 5.19.0-35-generic.

Thank you all for your help, and have a nice day.

Rishon JR avatar
pl flag
Different kernels may not be compatible with each computer. So older kernels are kept for older computers. and the duplicates are installed as a backup.
Rishon JR avatar
pl flag
The kernels are stored in the repositories. So if any bug in a newer version they can revert to and older kernel version.
guiverc avatar
cn flag
Ubuntu 22.04 LTS has two main kernel streams; the GA kernel is 5.15 for the life of the product, and HWE changes using kernels from later non-LTS releases meaning it recently switched from 5.15 to 5.19 (from 22.10). If you have GA & HWE kernel stacks installed (*not just a single one*), you'll keep 5.15 & whatever the HWE kernel is (*currently 5.19, next will be 6.1 some months away*) as well. FYI: There are also OEM kernels too, I've limited this common to what I consider the main GA & HWE kernel stack choices - https://wiki.ubuntu.com/Kernel/LTSEnablementStack
Kumaresh Balaji Sundararajan avatar
ve flag
@guiverc Thank you very much for your explanation. The link you provided was highly informative as well.
Kumaresh Balaji Sundararajan avatar
ve flag
@guiverc I never explicitly enabled the HWE stack, however I upgraded from an install of Ubuntu 20.04 which enables the HWE stack by default as per the link you shared. Thus, I was automatically enrolled for the HWE stack and also the GA stack when I upgraded to 22.04, and I realized it just now since 5.19 was distributed very recently. Thank you again for clarifying my doubts.
guiverc avatar
cn flag
FYI: Ubuntu 22.04 LTS Server defaults to the GA kernel stack, Ubuntu 22.04 LTS Desktop defaults to HWE kernel stack, with Ubuntu 22.04 LTS *flavors* the ISO used to install controls the state (just as with Ubuntu 18.04 LTS Desktop & earlier; eg. Lubuntu 22.04 & 22.04.1 media will default to GA, however Lubuntu 22.04.2 & later media defaults to HWE kernel stack). The difference between stacks is not a setting, but the packages installed; so if you *release-upgraded* from a prior release; you'll keep whatever stack(s) you had prior to *release-upgrade*. (*I used Lubuntu only as example..*)
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.