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
osutil/mkfs: disable orphan_file feature for ext4 #13373
Conversation
So just FTR, I believe the way to get the version of the host ubuntu is to utilize the information from |
d016e63
to
ad6a371
Compare
The current strategy is to check if we are running on a Lunar version. I saw we already do this kind of checks in other places in the code. What we really would like to do is check if mkfs.ext4 supports the orphan_file feature and disable it if so. But this is more complex change, probably needing to either execute mkfs.ext4 a first time or/and properly parse |
ad6a371
to
752744a
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #13373 +/- ##
==========================================
- Coverage 78.82% 78.82% -0.01%
==========================================
Files 1022 1022
Lines 127437 127447 +10
==========================================
+ Hits 100458 100460 +2
- Misses 20698 20703 +5
- Partials 6281 6284 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
I think that the alternative would be to include According to the mkfs.ext4 man page, there is an env var called
Doing things this way would make sure that cc @sil2100 |
@alfonsosanchezbeato thank you for the suggestion. I thought solving this in snapd would also prevent other use cases you may have from breaking. But if you think this is fine as is in snapd we can fix it in ubuntu-image. Quick question regarding your suggestion: It means we would need to maintain a list of |
Solving it in
Yes, it will be necessary to have such a list. In principle it should not be a big deal to download the latest version of |
OK, thanks. I was already convinced adding e2fsprogs in the snap was needed, it will kill two birds with one stone. Let's close this then. |
The SRU to fix LP #2025339 has been rejected. So I would like to find a solution in snapd to fix https://bugs.launchpad.net/ubuntu-image/+bug/2028564.
Currently I disabled the
orphan_file
feature in every case but this will not work for series older than lunar because this feature was not present (mkfs.ext4 fails with aInvalid filesystem option set: ^orphan_file
error). An ideal solution would be to do it only when running on Lunar. I am looking into it but do you know if there is already an easy way to check the series in snapd?Currently, calling mkfs.ext4 without any option will result in a filesystem with the orphan_file feature disabled on mantic and up, so we do not loose anything setting it up explicitly for now.