feat(base): grow every managed filesystem, online and on xfs - #48
Merged
Conversation
root_autoresize.sh called resize2fs unconditionally, so an xfs root was never grown after growpart. Detect the root filesystem type and dispatch to resize2fs (ext2/3/4) or xfs_growfs (xfs); fail loudly on anything else.
The autoresize service only handled the root partition, only at boot and only with resize2fs, so an xfs root failed the unit and secondary disks were never grown at all. Once prepare_persistent_disk formats a data disk its size was fixed forever, because the bootstrap unit runs once per machine. Generalise the script to walk mounted partitions, pick resize2fs or xfs_growfs by the actual filesystem, and skip what cannot be grown (an EFI system partition is mounted in every image). Add a udev rule on the RESIZE=1 change uevent so a disk enlarged under a running machine is picked up without a reboot, and keep a boot time sweep for disks that grew while the machine was off.
phantomii
reviewed
Jul 31, 2026
phantomii
requested changes
Jul 31, 2026
phantomii
left a comment
Member
There was a problem hiding this comment.
Changes requested: the XFS autoresize path is not deployable until the image installs xfsprogs and the path is covered by a test. See the inline comment.
The base image happens to ship mkfs.xfs and xfs_growfs today, so the xfs paths in prepare_persistent_disk and exordos_autoresize.sh work by accident. Depend on them explicitly so a future base image change cannot silently take them away.
phantomii
approved these changes
Jul 31, 2026
phantomii
left a comment
Member
There was a problem hiding this comment.
Approved: xfsprogs is now declared explicitly in the image build, which resolves the XFS runtime dependency.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.