<div dir="ltr"><p>Hi Brian:</p><p>First, let me state the title of the bug I filed was unfortunate and I’ve changed it accordingly. The body of the request shows that it is a proposal to increase the /boot partition size, but the title sounded demanding. Also, the file sizes were ambiguous. I have updated them both.</p><p><a href="https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/1960089" target="_blank">https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/1960089</a></p><p>> A consequence of Ubuntu being open and customizable is that users can do many things that are not ones that we endorse.</p><p>Agreed, but I believe Ubuntu should support multiple kernels for a few reasons:</p><p>1. We agree that the outcome of an overfull /boot partition can be catastrophic for less-than-expert users. It seems, therefore, that the system should help avoid this situation commiserate with its potential cost.</p><p>2. There are no obvious mechanisms to guide novice users with kernel management. Unless I’m missing something (always a possibility) there is no system that actively monitors the /boot partition *size* and warns users of filling disk (impending doom?). We did this (see <a href="https://kfocus.org/wf/tools#kclean" target="_blank">https://kfocus.org/wf/tools#kclean</a>) but we don’t know if or when this will be upstreamed.</p><p>3. Users install different kernel flavors for many legitimate workflows. Three examples immediately come to mind: 3.1) People who do low-latency A/V work frequently switch between the generic-hwe and lowlatency-hwe kernels; 3.2) The community often encourages users to explore different kernel flavors to improve hardware support; and 3.3) Developers switch to stock generic to test for deployment, then back to a later kernel, like hwe or oem, for better hardware support.</p><p>> We are all in agreement that the /boot partition size needs increasing</p><p>Agreed, and the increase you have made to 1.5G is much better.</p><p>> For us to move forward in the discussion about increasing it to 2G it would really help for you to answer my previous questions regarding the use cases for having multiple kernels installed. </p><p>>> I’d really like more information on the use case where multiple kernel flavors will be installed. You mention switching from HWE to OEM, given that this is a switch wouldn’t the HWE kernel be removed and then you are left with just one flavor of kernel?</p><p>Kernel packages rarely replace one another and so it is trivial to install generic (stock), generic-hwe, lowlatency-hwe, oem-20.04d, and others concurrently. This is a welcome feature as discussed in (3) above.</p><p>The calculations provided in <a href="https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/1960089" target="_blank">https://bugs.launchpad.net/ubuntu/+source/ubiquity/+bug/1960089</a> suggest that Ubuntu should support up to three flavors at once. For example, a user may have generic-hwe, lowlatency-hwe, and a third kernel flavor for hardware support (oem-20.04d) or deployment testing (linux-generic).</p><p>If we agree that supporting 3 concurrent kernel flavors is good, then what is a reasonable space requirement? During an upgrade, the /boot partition is first filled up with new package files before any cleanup by autoremove or unattended-upgrades can occur. Also, Ubuntu often updates multiple kernel flavors on the same day. For example, generic-hwe and lowlatency-hwe are almost always released concurrently. Thus, we can reasonably assume there will be times when the /boot partition will need to accommodate the files for 3 flavors and 2 versions each. The total, therefore, is 2 x 3 = 6 kernels.</p><p>We have found the files in /boot take over 180MiB for each kernel for a system with Nvidia hardware. Rounding up to 200MiB to accommodate for future growth, we get 6 x 200MiB = 1.2GiB minimum. Add space for 4 additional kernel images as a safety factor and we get 2.0GiB.</p><p>One might ask if maintaining room for 4 extra kernels is a reasonable safety factor, and that’s a fair question. Here are some edge cases to consider that can keep additional kernel images around: a) The running kernel package is never removed (see /etc/apt/apt.conf.d/01autoremove-kernels) which could keep an extra kernel; b) A metapackage has been constructed to transition to newer flavor (for example, upgrading oem-20.04c to oem-20.04d); c) The system has not had a cleaning event occur for a while and kernel packages have accumulated. My feeling is this safety factor is warranted given how expensive recovery is for most users.</p><p>I hope you find that useful, Brian, and thank you for your consideration.</p><p>Sincerely, Mike</p><p><br></p></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Feb 21, 2022 at 12:19 PM Brian Murray <<a href="mailto:brian@ubuntu.com" target="_blank">brian@ubuntu.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Tue, Feb 15, 2022 at 10:47:59PM -0800, Michael Mikowski wrote:<br>
> Hi Everyone:<br>
> <br>
> Aaron: On an encrypted Ubuntu system, the EFI partition mounted on<br>
> /boot/efi is 512M too. But here we are talking about the /boot partition<br>
> which is distinct. It is typically 705M and formatted with ext4, although<br>
> subsequent released will likely be larger. The question here is by how much.<br>
> <br>
> We have offered this suggestion as means to move a proven solution<br>
> component upstream for the benefit of everyone using 22.04. We implemented<br>
> an enlarged /boot partition and improved kernel management and cleaning<br>
> over a year ago because our customers needed it. See the support cost<br>
> calculations below about why we moved quickly when this became an issue. We<br>
> expected to see much more of if we didn't take action. The problem was made<br>
> more urgent by a packagekit bug.<br>
> <br>
> Using an additional 0.5% (1.295G costing < $0.25) of a 250G NVMe drive is a<br>
> very small price to pay to help avoid a catastrophic failure mode from<br>
> which most users cannot recover.<br>
<br>
When interviewing candidates for positions at Canonical I've had the<br>
opportunity to speak to Ubuntu users from around the world. Sometimes<br>
these are people who installed Ubuntu on whatever system they had lying<br>
around and they weren't in a position to buy a new PC or drive. So while<br>
the additional space in /boot might cost $0.25 for you, the cost for<br>
other people may be much greater. When developing Ubuntu we need to take<br>
into consideration the fact that our users are located in a variety of<br>
different countries and subsequently have access to different resources.<br>
<br>
> And users *do* install multiple kernels images for many legitimate and<br>
> exploratory reasons, and this *does* cause full disks on the default<br>
> partition size. If people are doing this, and the OS allows it (and it<br>
> should), then how can it not be a supported use case?<br>
<br>
A consequence of Ubuntu being open and customizable is that users can do<br>
many things that are not ones that we endorse.<br>
<br>
> Should we remove safety belts from cars because we arbitrarily decide that<br>
> braking hard is not a supported use case? Where are Ubuntu's supported use<br>
> cases, DFMEAs, and KPCs available for review?<br>
> <br>
> Compare the cost of $0.25 disk space versus the cost helping one novice<br>
> user recover an overfull /boot partition. This can easily exceed $200 in<br>
> direct support and lost productivity. That's 800 *times* more expensive.<br>
> Worse, if the user can't find help expert-level assistance, they are highly<br>
> motivated to abandon Ubuntu altogether.<br>
> <br>
> If Ubuntu is for everyone, then we should be catering to the vast majority<br>
> to whom the $0.25 of disk space doesn't matter. These users also often lack<br>
> the deep skill set to recover from this failure mode. Conversely, the tiny<br>
> fraction who want to optimize /boot size are those best equipped to do so -<br>
> they are typically on a much smaller disk and are creating custom<br>
> installations for things like embedded or edge systems. The installer is no<br>
> impediment for these professionals.<br>
> <br>
> We could continue discussing minutia about why this may or may not be a<br>
> good idea, however, I believe the cost / benefit analysis above is highly<br>
> convincing. We are confident from experience that a 2G /boot partition is a<br>
> very good choice that works with best practice for all common and readable<br>
> use cases. A quick web search also shows this size is frequently<br>
> recommended by other experienced desktop Linux users.<br>
<br>
We are all in agreement that the /boot partition size needs / needed<br>
increasing. For us to move forward in the discussion about increasing it<br>
to 2G it would really help for you to answer my previous questions<br>
regarding the use cases for having multiple kernels installed. Those<br>
questions were in the following email:<br>
<br>
<a href="https://lists.ubuntu.com/archives/ubuntu-devel/2022-February/041856.html" rel="noreferrer" target="_blank">https://lists.ubuntu.com/archives/ubuntu-devel/2022-February/041856.html</a><br>
<br>
Cheers,<br>
--<br>
Brian Murray<br>
</blockquote></div>