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

lib/deploy: Round to block size in early prune space check #3130

Merged
merged 2 commits into from
Jan 4, 2024

Commits on Jan 4, 2024

  1. lib/deploy: Round to block size in early prune space check

    When we estimate how much space a new bootcsum dir will use, we
    weren't accounting for the space overhead from files not using the
    last filesystem block completely. This doesn't matter much if counting
    a few files, but e.g. on FCOS aarch64, we include lots of small
    devicetree blobs in the bootfs. That loss can add up to enough for the
    `fallocate()` check to pass but copying still hitting `ENOSPC` later on.
    
    I think a better fix here is to change approach entirely and instead
    refactor `install_deployment_kernel()` so that we can call just the
    copying bits of it as part of the early prune logic. We'll get a more
    accurate assessment and it's not lost work since we won't need to
    recopy later on. Also this would not require having to keep in sync the
    estimator and the install bits.
    
    That said, this is blocking FCOS releases, so I went with a more tactical
    fix for now.
    
    Fixes: coreos/fedora-coreos-tracker#1637
    jlebon committed Jan 4, 2024
    Configuration menu
    Copy the full SHA
    4982306 View commit details
    Browse the repository at this point in the history
  2. lib/deploy: Add safety margin in early prune space check

    There are a few things the estimator doesn't account for, e.g. writing
    the new BLS entries. Rather than trying to perfect it (since I think we
    should change approach entirely -- see previous commit message), just
    add a 1M margin to the space check.
    jlebon committed Jan 4, 2024
    Configuration menu
    Copy the full SHA
    cc5747a View commit details
    Browse the repository at this point in the history