Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

calculation of disk partition sizes is messy. #27

Open
tolland opened this issue Oct 30, 2021 · 0 comments
Open

calculation of disk partition sizes is messy. #27

tolland opened this issue Oct 30, 2021 · 0 comments

Comments

@tolland
Copy link
Member

tolland commented Oct 30, 2021

So currently, to build the recovery partition, we need to know the following:

  1. what is the source of the recovery partition filesystem (i.e. is it a copy of the rootfs, or some slim/minimal filesystem?)
  2. how much free space is available in the recovery partition
  3. how big is the zipped rootfs file? (as it needs to fit in the free space in the recovery filesystem)
  4. how much free space padding is required for the recoveryfs to boot and do stuff (like logging, journal, caches etc)

These values need to be calculated, and the recovery partition and filesystem need to be sized accordingly.

These values can vary wildly depending on how big the zipped rootfs ends up being (depending on it being lite, desktop or full Pi OS etc) and also how much spare space is available on the recovery filesystem.

Currently the code to do this is nasty, and made more difficult by using bash to do the arithmetic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant