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

[RFE] warn/fail early if available disk space is too low to complete a build #3588

Open
miabbott opened this issue Jul 31, 2023 · 2 comments

Comments

@miabbott
Copy link

In #3582, I ran into an issue where my build of the iot-installer artifact failed because I had ran out of disk space.

In the case of a simple iot-installer build, the build process required ~13GB of disk space to generate a 2.4GB ISO artifact. I only had about 7GB of space available and as such, the build failed during the squashfs stage.

While it would be great if all users were more aware of the available disk space, it would be even better if the osbuild-composer CLI could warn the user (or outright fail) before submitting the build to osbuild. (Not sure how this could work for API users, but maybe it could just be a CLI improvement?)

I understand that the size of an artifact may grow based on the content being included in a build, so it may be impossible to know the final size of the artifact or required amount of space for a build, but I think putting some minimal guardrails in place would be useful.

@teg
Copy link
Member

teg commented Jul 31, 2023

This would indeed be useful, though possibly hard.

I think there are two aspects: get an estimate after depsolving (maybe dnf can help?); and get better error messages when we actually run out of space during image build (which can happen at any time and cause all sorts of errors)....

@bcl
Copy link
Contributor

bcl commented Jul 31, 2023

It probably would be more reliable to base it on the disk image size, maybe require 2x the target size as a minimum. The estimates from dnf aren't very accurate, and actual disk usage also depend on things like number of files and block size if you really want to get close. Throw btrfs into the mix and you can squeeze in more, but you don't know how much more :) With Anaconda we always ended up needing to add some kind of fudge factor, and that's just for a straight install to disk.

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

3 participants