• Welcome to Peterborough Linux User Group (Canada) Forum.
 

Keeping the old (but supported) kernel in Ubuntu 20.04

Started by fox, April 20, 2020, 12:53:23 PM

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

fox

This morning when I went to update my 20.04 system (using Software Update), among the updates was a deletion of my 18.04, but still supported kernel. (This is 4.15.) Since 4.15 boots nicely on my 5k iMac, but the latest kernel (5.4) doesn't, I unchecked the option to delete the 4.15 kernel. This deletion default is new; it hadn't come up on system updates until today. This concerns me because I might accidentally let the deletion occur. Also, I had been thinking about deleting the new kernel so that the default boot would be the 4.15. Is there some way I can at least get Software Update to stop offering to delete the 4.15 kernel?
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

fox

Well I got an answer of sorts from the Ubuntu forums. It seems that if I delete the 5.4 kernel, I won't be asked to delete the 4.15 kernel. However, there seems to be some question as to whether the 4.15 kernel is actually supported in Ubuntu 20.04, even though Canonical is supporting the 4.15 kernel for three more years in Ubuntu 18.04. If it isn't supported in 20.04, I wouldn't be getting security updates for that kernel, which would put me at risk. Perhaps all this means is I have to find another Canonical source for the updated debs and install them myself?
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

Jason

Because the 4.15 kernel still has three more years, it's not going to 'expire' and you will continue to get security updates for it. That kernel is also an LTS kernel which means it will be supported and you will get updates. At least that's my understanding but you can just try it and you fill out fairly soon since kernel updates are released every few months or more often. Depends on when they find vulnerabilities or bugs.

Since they're continuing to support the 4.x kernel series, it's easy for them to give you the security updates, too, so I imagine they will. If it wasn't going to be supported, they wouldn't let you keep it. They'd force you upgrade.

Linux Mint, btw, has a selector in the Update Manager that lets you choose from a wide range of kernels which will continue to be updated, or at least until it tells you it's no longer supported. And you can switch between on boot. I never played with the feature but it's there. I'm still using a 4.x series kernel on the PLUG server.
* Zorin OS 17.1 Core and Windows 11 Pro on a Dell Precision 3630 Tower with an
i5-8600 3.1 GHz 6-core processor, dual 22" displays, 16 GB of RAM, 512 GB Nvme and a Geforce 1060 6 GB card
* Motorola Edge (2022) phone with Android 13

fox

I hope you're right, Jason, but if you're not, there is always Linux Mint. I'm keeping Mint 19.3 on a partition. They will be updating it soon based on Ubuntu 20.20, but that's OK. When they updated it last, I got rid of the newest kernel that didn't work, and I have been getting regular kernel updates on 4.14. I don't know why Ubuntu would do this differently.

I have one other fallback on Ubuntu - the proprietary AMD drivers. I tried installing the current ones but it didn't work. However, they haven't issued a version yet for 20.04.
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

Jason

Quote from: fox on April 20, 2020, 07:46:46 PM
I hope you're right, Jason, but if you're not, there is always Linux Mint. I'm keeping Mint 19.3 on a partition. They will be updating it soon based on Ubuntu 20.20, but that's OK. When they updated it last, I got rid of the newest kernel that didn't work, and I have been getting regular kernel updates on 4.14. I don't know why Ubuntu would do this differently.

I have one other fallback on Ubuntu - the proprietary AMD drivers. I tried installing the current ones but it didn't work. However, they haven't issued a version yet for 20.04.


I would imagine if it wasn't getting updates, you could just switch back to the newer one, no?
* Zorin OS 17.1 Core and Windows 11 Pro on a Dell Precision 3630 Tower with an
i5-8600 3.1 GHz 6-core processor, dual 22" displays, 16 GB of RAM, 512 GB Nvme and a Geforce 1060 6 GB card
* Motorola Edge (2022) phone with Android 13

fox

Painful! Two minute boot, 2 minute shutdown, 2 minute wake from sleep!
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

Jason

Is that with the 4.15 kernel or the new 5.x series?
* Zorin OS 17.1 Core and Windows 11 Pro on a Dell Precision 3630 Tower with an
i5-8600 3.1 GHz 6-core processor, dual 22" displays, 16 GB of RAM, 512 GB Nvme and a Geforce 1060 6 GB card
* Motorola Edge (2022) phone with Android 13

fox

The 5x series. Boot time is less than 25 seconds to a working desktop with 4.15! Wake-up from sleep is less than 10 seconds and shut-down is about 20 seconds when running 4.15. Quite a difference!

The big nasty is the wake-up from sleep. I say that because I only boot and shut down once a day and I can do something else during boot and leave it to shut down on its own. But I want the computer to sleep when I'm not actively using it, and I'm not going to wait 2 minutes for it to wake up.

I never thought of this upgrade problem with the older 4.15 kernel until a moderator in the Ubuntu "Development" forum mentioned this in response to my post. I don't want to use a distro that is not getting security updates and I don't know whether he is right or not. I do know that Linux Mint 19.3, which is based on Ubuntu 18.04, is using a higher numbered version of the 4.15 kernel than Ubuntu is (at least Ubuntu 20.04). Is that because they are maintaining that kernel while Ubuntu 20.04 won't be? In the case of Mint, it offered to upgrade to a newer kernel when I upgraded Mint to 19.1 or 19.2, but I was able to remove it (boot problem again) and now I'm only offered updates to the 4.15 kernel. But Mint will soon be upgrading and will be based on Ubuntu 20.04. I assume that at that point, they will no longer be maintaining the 4.15 kernel either.

This problem is forcing me to think about whether I want to use my relatively new and powerful iMac as a Linux computer at all.
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

Jason

Quote from: fox on April 21, 2020, 08:58:38 AM
The big nasty is the wake-up from sleep. I say that because I only boot and shut down once a day and I can do something else during boot and leave it to shut down on its own. But I want the computer to sleep when I'm not actively using it, and I'm not going to wait 2 minutes for it to wake up.

Is it in sleep mode? Or hibernation?

Hibernation will always take longer because it has to read the disk back into memory, so however much memory you were using has to be read from the HDD or SSD.

I don't bother with sleep or hibernation in Linux. I find it never works the way I want it to and hibernation takes too long. The only thing I'd need to remember the state of is the browser tabs that are open and that can be done by changing a setting in the browser or saving all tabs into a bookmark folder. Hibernation doesn't waste energy at least, at least I don't think it does but if it does it's very little. It might still keep the hard drive powered on so it's ready to go on exit from hiberation. But much less than sleep which keeps power to the RAM and I think the processor goes into a low-power mode as well as the HDD or SDD. Unless you really have to have the computer ready in faster than 30 seconds (the boot time you mentioned), you shouldn't use sleep. If it is 30 seconds. You mentioned the 2 minutes again after just saying that that you had cut down the boot time. In any case, using sleep wears down the battery and wastes energy. I just mention that to you since you're an environment professor emeritus. :)

QuoteI never thought of this upgrade problem with the older 4.15 kernel until a moderator in the Ubuntu "Development" forum mentioned this in response to my post. I don't want to use a distro that is not getting security updates and I don't know whether he is right or not.

Am I missing something here? What did he/she say?

QuoteI do know that Linux Mint 19.3, which is based on Ubuntu 18.04, is using a higher numbered version of the 4.15 kernel than Ubuntu is (at least Ubuntu 20.04). Is that because they are maintaining that kernel while Ubuntu 20.04 won't be?

They're not maintaining it. They're just using the generic kernel and probably configuring the way they want, same as Ubuntu would be. Neither of them "maintain" the kernel as such. I mean that they're not actively contributing it unless a developer from one of those is actually on the kernel team. Linux Mint 20 will be using the 5.x kernel series. However, you can use older kernels just by accessing the menu in Update Manager and choosing one or more.

Why do you think that Linux Mint won't be supporting the 4.x kernel after it is based on Ubuntu 20.04? The 4.x kernel will continue to be updated because 18.04 uses it. And 18.04 doesn't reach end-of-life until 2023.
* Zorin OS 17.1 Core and Windows 11 Pro on a Dell Precision 3630 Tower with an
i5-8600 3.1 GHz 6-core processor, dual 22" displays, 16 GB of RAM, 512 GB Nvme and a Geforce 1060 6 GB card
* Motorola Edge (2022) phone with Android 13

fox

Quote from: Jason Wallwork on April 21, 2020, 11:05:28 AM
Is it in sleep mode? Or hibernation?

Hibernation will always take longer because it has to read the disk back into memory, so however much memory you were using has to be read from the HDD or SSD.

I don't bother with sleep or hibernation in Linux. I find it never works the way I want it to and hibernation takes too long. The only thing I'd need to remember the state of is the browser tabs that are open and that can be done by changing a setting in the browser or saving all tabs into a bookmark folder. Hibernation doesn't waste energy at least, at least I don't think it does but if it does it's very little. It might still keep the hard drive powered on so it's ready to go on exit from hiberation. But much less than sleep which keeps power to the RAM and I think the processor goes into a low-power mode as well as the HDD or SDD. Unless you really have to have the computer ready in faster than 30 seconds (the boot time you mentioned), you shouldn't use sleep. If it is 30 seconds. You mentioned the 2 minutes again after just saying that that you had cut down the boot time. In any case, using sleep wears down the battery and wastes energy. I just mention that to you since you're an environment professor emeritus. :)
I actually don't know. Looking at my Power Saving settings, automatic suspend is off, and the screen is set to go blank in 10 minutes if no input. I don't know what it's doing when it goes blank, but when I leave the computer and revive the blank screen later, it takes forever. With kernel 4.15, it "wakes up" almost instantly as soon as I press a key and type in my password.
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

fox

Quote from: Jason Wallwork on April 21, 2020, 11:05:28 AM
Am I missing something here? What did he/she say?
"The 4.15 kernel series is not supported on 20.04.
(It runs? Sure. Is it available to install from the official repositories? I don't think so, maybe. But it is definitely not a supported kernel.)"
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

fox

Quote from: Jason Wallwork on April 21, 2020, 11:05:28 AM
Why do you think that Linux Mint won't be supporting the 4.x kernel after it is based on Ubuntu 20.04? The 4.x kernel will continue to be updated because 18.04 uses it. And 18.04 doesn't reach end-of-life until 2023.
Because I will update to Mint 20 once it becomes available and that will be based on Ubuntu 20.04. Sure I can stay on 19.3 for awhile and the 4.15 kernel would be maintained. I can do the same by staying on Ubuntu 18.04. But neither is a good option to me.

Incidentally, the choice of staying with the 4.15 kernel in Ubuntu 20.04 has apparently been taken out of my hands. After an update yesterday, when I went to boot, the 4.15 kernel wasn't an option. When I looked for 4.15 on Synaptic, the linux-image was listed unchecked, but wouldn't install. When I tried, I got the message: "Package linux-image-4.15.0-72-generic has no available version, but exists in the database.
This typically means that the package was mentioned in a dependency and never uploaded, has been obsoleted or is not available with the contents of sources.list".

When I looked at the repositories in Software and Updates, there were several Bionic Beaver (18.04) repositories listed, but all were unchecked, and all were source code. None of the Ubuntu Bionic binary repositories were even listed.
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13

Jason

Quote from: fox on April 21, 2020, 11:19:52 AM
"The 4.15 kernel series is not supported on 20.04.
(It runs? Sure. Is it available to install from the official repositories? I don't think so, maybe. But it is definitely not a supported kernel.)"

What is his position or his experience with Ubuntu? Is he a developer, a maintainer of Ubuntu or just a moderator. I say "just" which kind of mean but I'm just a moderator and member of PLUG, too. But I ask because maybe he's wrong. If you use LM instead, the 19.x series is supported until 2022, I believe, at least. And it will have the 4.x series. But honestly, Fox, don't worry so much. Just keep the kernel you like and see what happens.

Since I use 4.x series on the PLUG server, I can tell you if I see updates and let you know. I'll also check to see if it's the same version number you're using exactly. If you don't see updates when I do then you know it's not being updated.

It's not like there's any rush, right? Even 19.10 is supported for 9 months so you could regress. You can still get newer versions of the programs you are specifically interested via snaps or repositories. Or get LM and you can continue using the 19.x version even when LM 20 comes out.
* Zorin OS 17.1 Core and Windows 11 Pro on a Dell Precision 3630 Tower with an
i5-8600 3.1 GHz 6-core processor, dual 22" displays, 16 GB of RAM, 512 GB Nvme and a Geforce 1060 6 GB card
* Motorola Edge (2022) phone with Android 13

Jason

Quote from: fox on April 21, 2020, 11:27:12 AM
Incidentally, the choice of staying with the 4.15 kernel in Ubuntu 20.04 has apparently been taken out of my hands. After an update yesterday, when I went to boot, the 4.15 kernel wasn't an option.


Okay, that's weird. You might have to move to LM then. I know for a fact that you can have multiple kernel versions on it at the same time.
* Zorin OS 17.1 Core and Windows 11 Pro on a Dell Precision 3630 Tower with an
i5-8600 3.1 GHz 6-core processor, dual 22" displays, 16 GB of RAM, 512 GB Nvme and a Geforce 1060 6 GB card
* Motorola Edge (2022) phone with Android 13

fox

Quote from: Jason Wallwork on April 21, 2020, 02:02:00 PM

Okay, that's weird. You might have to move to LM then. I know for a fact that you can have multiple kernel versions on it at the same time.
It is weird, and it wasn't replicated in a replicate partition I made on the same computer. But in that case I may have been more careful. After I updated the 5.4 kernel in that partition, I deleted the older 5.4 kernel before rebooting. I don't know if it was because of this action that the 4.15 kernel stayed around, or maybe I accidentally did an autoremove in the other partition without thinking.

So now another mystery. I have two 20.04 partitions on the same computer, one with and one without the 4.15 kernel. I opened up the Software and Updates application, expecting to find a repo in the one with the 4.15 kernel that isn't in the other partition. Nope; at least it wasn't obvious if there is one. And no Ubuntu 18.04 repos are enabled as far as I can tell. So why when I search "4.15.0-" in Synaptic do I come up with all these 4.15 kernel files, including a bunch of 4.15.0-x versions? In both partitions! Where are they coming from? Is there a way I can find out?

If you take the example of the 20.04 partition with 4.15 kernel no longer an option, I see the listing in Synaptic for the linux image but I can't reinstall it. Where would I get that from if I want to put it back? And wherever that is, wouldn't they have an updated version when this kernel gets its next security update?

Too many questions and not enough answers. So here is another one for you. In my situation, would you run the 4.15 kernel if you knew it wasn't being updated?  :-\
Ubuntu 24.10 on 2019 5k iMac
Ubuntu 24.04 on Dell XPS 13